forked from mouredev/roadmap-retos-programacion
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request mouredev#4226 from MemoGV/main
#00 - JavaScript y mouredev#1 - JavaScript
- Loading branch information
Showing
2 changed files
with
94 additions
and
0 deletions.
There are no files selected for viewing
17 changes: 17 additions & 0 deletions
17
Roadmap/00 - SINTAXIS, VARIABLES, TIPOS DE DATOS Y HOLA MUNDO/javascript/memoGV.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
|
||
/*Hola mouredev, empezando con los retos de prgramacion, espero no sea demasiado tarde | ||
https://developer.mozilla.org/en-US/ */ //Diferente Comentario// | ||
|
||
let a = 1 | ||
var b = 2 | ||
const c = b - a | ||
|
||
let numero = 0 | ||
let string = "Hola" | ||
let boleano = true | ||
let sinDefinir = undefined | ||
let nulo = null | ||
let simbolo = Symbol('descripcion') | ||
let numeroGrande = BigInt(909090909090909090909) | ||
|
||
console.log('Hola JavaScript') |
77 changes: 77 additions & 0 deletions
77
Roadmap/01 - OPERADORES Y ESTRUCTURAS DE CONTROL/javascript/memoGV.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
|
||
let suma = 2 + 2 | ||
let resta = suma -2 | ||
let multiplicacion = suma * 2 | ||
let division = multiplicacion / 2 | ||
let resto = division % 2 | ||
let incrementa = suma++ | ||
let decrementa = resta-- | ||
let exponente = 2 ** 3 | ||
|
||
let asignacion = 2 = 2 | ||
let asignacionSuma = 2 += 2 | ||
let asignacionResta = 2 -= 2 | ||
let asignacionMultiplicacion = 2 *= 2 | ||
let asignacionDivision = 2 /= 2 | ||
let asignacionResto = 2 %= 2 | ||
let asignacionExponente = 2 **= 2 | ||
|
||
let igualdad = 2 == 2 | ||
let igualdadEstricta = 2 === 2 | ||
let desigualdad = 2 != 2 | ||
let desigualdadEstricta = 2 !== 2 | ||
let mayorQue = 2 > 2 | ||
let menorQue = 2 < 2 | ||
let menorQueOIgual = 2 <= 2 | ||
let mayorQueOIgual = 2 >= 2 | ||
let and = 2 && 2 | ||
let or = 2 || 2 | ||
let not = !2 | ||
|
||
if(suma > 2){ | ||
console.log("Es mayor") | ||
}else{ | ||
console.log("Es menor")} | ||
|
||
switch(suma){ | ||
case 1: console.log("Es 1"); | ||
break; | ||
default: console.log("Es otro valor") | ||
} | ||
|
||
for(let i = 0; i<10; i++){ | ||
console.log(i) | ||
} | ||
|
||
while(suma < 10){ | ||
console.log(suma) | ||
suma++ | ||
} | ||
|
||
do{ | ||
console.log(suma) | ||
i++ | ||
}while(i<5) | ||
|
||
// Programa para imprimir por consola | ||
|
||
const printNumbers =(num1, num2)=>{ | ||
|
||
while(num1 < num2){ | ||
|
||
if(num1 === 16 || num1%3 === 0){ | ||
num1++ | ||
continue | ||
} | ||
|
||
if(num1 >= 10 && num1 <=55){ | ||
console.log(num1) | ||
}else if(num1%2 === 0){ | ||
console.log(num1) | ||
} | ||
num1++ | ||
} | ||
} | ||
|
||
printNumbers(4, 90); | ||
|