본문 바로가기

Python_WEB/JavaScript

[freecodecamp]JavaScript 다른 숫자에서 하나의 숫자 빼기

반응형

한 숫자에서 다른 숫자를 뺄 수도 있습니다.

JavaScript는 빼기를 위해 - 기호를 사용합니다.

 

예>

myVar = 12 - 6; // assigned 6

 

Q>

1. difference 변수가 12가되도록 0을 변경합니다.

2. difference 변수는 12와 같아야합니다.

3. 45에서 하나의 숫자만 빼야합니다.

 

A>

var difference = 45 - 33;

 

https://www.freecodecamp.org/

 

freeCodeCamp.org

Learn to code. Build projects. Earn certifications.Since 2015, 40,000 graduates have gotten jobs at tech companies including Google, Apple, Amazon, and Microsoft.

www.freecodecamp.org

 

반응형