JavaScript syntax is the set of rules, how JavaScript programs are constructed:
자바스크립트 문법은 어떻게 자바스크립트 프로그램들이 구성되어있는가를 정의하는 규칙의 집합이다.
JavaScript Values
The JavaScript syntax defines two types of values: Fixed values and variable values.
Fixed values are called literals. Variable values are called variables.
자바스크립트 변수
자바스크립트 문법은 두가지 변수의 타입을 정의한다.
고정된 변수 변할수 있는 변수
고정된 변수는 literals라고 불리운다
변할수 있는 변수는 variables라고 불리운다.
JavaScript Literals
The most important rules for writing fixed values are:
Numbers are written with or without decimals:
고정된 변수를 작성하기 위한 가장 중요한 규칙은 다음과 같다.
숫자는 십진수로 작성되거나? 아닌것으로 작성된다?
Strings are text, written within double or single quotes:
스트링은 텍스트이고,더블이나 싱글쿼트로 작성되어진다.
JavaScript Variables
In a programming language, variables are used to store data values.
JavaScript uses the var keyword to declare variables.
An equal sign is used to assign values to variables.
In this example, x is defined as a variable. Then, x is assigned (given) the value 6:
자바스크립트 변수
프로그래밍 언어에서, 변수는 값을 저장하기 위해 사용되어진다.
자바스크립트는 변수를 선언하기 위해서 var 키워드를 사용한다.
"=" 는 변수에 값을 어사인 하기 위해 사용되어진다.
예를들면 x는 변수로서 선언되었고, 그런다음 x에 값 6을 할당한다.
JavaScript Operators
JavaScript uses arithmetic operators ( + - * / ) to compute values:
자바스크립트는 값을 계산하기 위해 수학적 오퍼레이터를 사용한다.
JavaScript uses an assignment operator ( = ) to assign values to variables:
자바스크립트는 변수에 값을 할당하기 위해 "="를 사용한다.
JavaScript Expressions
An expression is a combination of values, variables, and operators, which computes to a value.
The computation is called an evaluation.
For example, 5 * 10 evaluates to 50:
표현식은 변할수 있는 값과 값을 계산하기 위한 오퍼레이터의 결합이고
컴퓨테이션은 evaluation이라고 불리운다.
예를들면 5*10은 50으로 계산된다.
Expressions can also contain variable values:
표현식은 변할수 있는 변수를 포함한다.
The values can be of various types, such as numbers and strings.
For example, "John" + " " + "Doe", evaluates to "John Doe":
값은 숫자와 스트링같은 변수 타입이 될수 있다.
예를들면, "John" + " " + "Doe" 는 "John Doe"로계산된다.
JavaScript Keywords
JavaScript keywords are used to identify actions to be performed.
The var keyword tells the browser to create variables:
자바스크립트 키워드
자바스크립트 키워드는 수행되어지는 행동들의 정의하기 위해서 사용되어진다.
var 키워드는 브라우저에게 변수를 만들어라 라고 말한다.
JavaScript Comments
Not all JavaScript statements are "executed".
Code after double slashes // or between /* and */ is treated as a comment.
Comments are ignored, and will not be executed:
자바스크립트 주석
자바스크립트의 모든 문장이 수행되진 않는다.
"//" 후에 오는 코드나, /* */ 사이에 코드들은 주석으로서 대해진다.
주석은 무시받고, 수행되지 않는다.
JavaScript Identifiers
Identifiers are names.
In JavaScript, identifiers are used to name variables (and keywords, and functions, and labels).
The rules for legal names are much the same in most programming languages.
In JavaScript, the first character must be a letter, or an underscore (_), or a dollar sign ($).
Subsequent characters may be letters, digits, underscores, or dollar signs.
Numbers are not allowed as the first character.
This way JavaScript can easily distinguish identifiers from numbers.
자바스크립트에서 identifiers 는 변수에게 이름을 주기위해 사용되어진다.
이름을 짓기위한 합법적인 규칙은 대부분의 프로그래밍 랭기지와 같다?
자바스크립트에서 첫번제 문자는 문자나 "_" 혹은"$"여야만 한다.
다음의 문자는 문자나 숫자 _ $ 일수 있다.
숫자는 첫번째로 허영되지 않는다.
이것은 자바스크립트를 숫자로부터 identifiers 를 구분하기 쉽게한다.
JavaScript is Case Sensitive
All JavaScript identifiers are case sensitive.
The variables lastName and lastname, are two different variables:
자바스크립트는 대소문자에 민감하다.
모든 자바스크립트 identifiers는 대소문자에 민감하다.
lastName과 lastname의 변수는 다른 변수이다.
JavaScript and Camel Case
Historically, programmers have used different ways of joining multiple words into one variable name:
Hyphens:
first-name, last-name, master-card, inter-city.
Hyphens are not allowed in JavaScript. They are reserved for subtractions.
Underscore:
first_name, last_name, master_card, inter_city.
Upper Camel Case (Pascal Case):
FirstName, LastName, MasterCard, InterCity.
Lower Camel Case:
JavaScript programmers tend to use camel case that starts with a lowercase letter:
firstName, lastName, masterCard, interCity.
자바스크립트 그리고 카멜
역사적으로 프로그래머들은 하나의 변수이름에 여러개의 단어를 합치기 위한 방법을 사용해 왔다.
'영어공부' 카테고리의 다른 글
JavaScript Variables (0) | 2020.02.12 |
---|---|
JavaScript Comments (0) | 2020.02.12 |
JavaScript Statements (0) | 2020.01.23 |
JavaScript Output (0) | 2020.01.23 |
JavaScript Where To (0) | 2020.01.23 |
JavaScript syntax is the set of rules, how JavaScript programs are constructed:
자바스크립트 문법은 어떻게 자바스크립트 프로그램들이 구성되어있는가를 정의하는 규칙의 집합이다.
JavaScript Values
The JavaScript syntax defines two types of values: Fixed values and variable values.
Fixed values are called literals. Variable values are called variables.
자바스크립트 변수
자바스크립트 문법은 두가지 변수의 타입을 정의한다.
고정된 변수 변할수 있는 변수
고정된 변수는 literals라고 불리운다
변할수 있는 변수는 variables라고 불리운다.
JavaScript Literals
The most important rules for writing fixed values are:
Numbers are written with or without decimals:
고정된 변수를 작성하기 위한 가장 중요한 규칙은 다음과 같다.
숫자는 십진수로 작성되거나? 아닌것으로 작성된다?
Strings are text, written within double or single quotes:
스트링은 텍스트이고,더블이나 싱글쿼트로 작성되어진다.
JavaScript Variables
In a programming language, variables are used to store data values.
JavaScript uses the var keyword to declare variables.
An equal sign is used to assign values to variables.
In this example, x is defined as a variable. Then, x is assigned (given) the value 6:
자바스크립트 변수
프로그래밍 언어에서, 변수는 값을 저장하기 위해 사용되어진다.
자바스크립트는 변수를 선언하기 위해서 var 키워드를 사용한다.
"=" 는 변수에 값을 어사인 하기 위해 사용되어진다.
예를들면 x는 변수로서 선언되었고, 그런다음 x에 값 6을 할당한다.
JavaScript Operators
JavaScript uses arithmetic operators ( + - * / ) to compute values:
자바스크립트는 값을 계산하기 위해 수학적 오퍼레이터를 사용한다.
JavaScript uses an assignment operator ( = ) to assign values to variables:
자바스크립트는 변수에 값을 할당하기 위해 "="를 사용한다.
JavaScript Expressions
An expression is a combination of values, variables, and operators, which computes to a value.
The computation is called an evaluation.
For example, 5 * 10 evaluates to 50:
표현식은 변할수 있는 값과 값을 계산하기 위한 오퍼레이터의 결합이고
컴퓨테이션은 evaluation이라고 불리운다.
예를들면 5*10은 50으로 계산된다.
Expressions can also contain variable values:
표현식은 변할수 있는 변수를 포함한다.
The values can be of various types, such as numbers and strings.
For example, "John" + " " + "Doe", evaluates to "John Doe":
값은 숫자와 스트링같은 변수 타입이 될수 있다.
예를들면, "John" + " " + "Doe" 는 "John Doe"로계산된다.
JavaScript Keywords
JavaScript keywords are used to identify actions to be performed.
The var keyword tells the browser to create variables:
자바스크립트 키워드
자바스크립트 키워드는 수행되어지는 행동들의 정의하기 위해서 사용되어진다.
var 키워드는 브라우저에게 변수를 만들어라 라고 말한다.
JavaScript Comments
Not all JavaScript statements are "executed".
Code after double slashes // or between /* and */ is treated as a comment.
Comments are ignored, and will not be executed:
자바스크립트 주석
자바스크립트의 모든 문장이 수행되진 않는다.
"//" 후에 오는 코드나, /* */ 사이에 코드들은 주석으로서 대해진다.
주석은 무시받고, 수행되지 않는다.
JavaScript Identifiers
Identifiers are names.
In JavaScript, identifiers are used to name variables (and keywords, and functions, and labels).
The rules for legal names are much the same in most programming languages.
In JavaScript, the first character must be a letter, or an underscore (_), or a dollar sign ($).
Subsequent characters may be letters, digits, underscores, or dollar signs.
Numbers are not allowed as the first character.
This way JavaScript can easily distinguish identifiers from numbers.
자바스크립트에서 identifiers 는 변수에게 이름을 주기위해 사용되어진다.
이름을 짓기위한 합법적인 규칙은 대부분의 프로그래밍 랭기지와 같다?
자바스크립트에서 첫번제 문자는 문자나 "_" 혹은"$"여야만 한다.
다음의 문자는 문자나 숫자 _ $ 일수 있다.
숫자는 첫번째로 허영되지 않는다.
이것은 자바스크립트를 숫자로부터 identifiers 를 구분하기 쉽게한다.
JavaScript is Case Sensitive
All JavaScript identifiers are case sensitive.
The variables lastName and lastname, are two different variables:
자바스크립트는 대소문자에 민감하다.
모든 자바스크립트 identifiers는 대소문자에 민감하다.
lastName과 lastname의 변수는 다른 변수이다.
JavaScript and Camel Case
Historically, programmers have used different ways of joining multiple words into one variable name:
Hyphens:
first-name, last-name, master-card, inter-city.
Hyphens are not allowed in JavaScript. They are reserved for subtractions.
Underscore:
first_name, last_name, master_card, inter_city.
Upper Camel Case (Pascal Case):
FirstName, LastName, MasterCard, InterCity.
Lower Camel Case:
JavaScript programmers tend to use camel case that starts with a lowercase letter:
firstName, lastName, masterCard, interCity.
자바스크립트 그리고 카멜
역사적으로 프로그래머들은 하나의 변수이름에 여러개의 단어를 합치기 위한 방법을 사용해 왔다.
'영어공부' 카테고리의 다른 글
JavaScript Variables (0) | 2020.02.12 |
---|---|
JavaScript Comments (0) | 2020.02.12 |
JavaScript Statements (0) | 2020.01.23 |
JavaScript Output (0) | 2020.01.23 |
JavaScript Where To (0) | 2020.01.23 |