Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Basic/00-helloworld.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Vídeo: https://youtu.be/1glVfFxj8a4?t=2390

/*
Esto es
un comentario
un comentario k
en varias líneas
*/

Expand Down
20 changes: 20 additions & 0 deletions Basic/00-holamundo.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
//Esto es un comentario simple


/*esto
es
un
comentario
en varias líneas*/


console.log("¡Hola, JavaScript");
console.log('Hola JavaScript')

console.log(5)
console.log("5")
console.log(5 + 2)
console.log(5 - 2)
console.log(5 / 2)
console.log(5 % 2)
console.log(5 ** 2)
24 changes: 24 additions & 0 deletions Basic/01-variablesmaria.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
//var

var helloWorld = " Hola,JavaScript "
console.log(helloWorld)

helloWorld = " Hola de nuevo, Javascript "
console.log(helloWorld)

//let
let helloWorld2 = " Hola,JavaScript 2 "
console.log(helloWorld2)

helloWorld2 = " Hola de nuevo, Javascript 2 "
console.log(helloWorld2)

//const
const helloworld3 = " Hola JavaScript 3 "
console.log(helloworld3)


//Error
//helloworld3 = " Hola de nuevo, JavaScript 2 "
//console.log(helloworld3)

2 changes: 1 addition & 1 deletion Basic/02-datatypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Vídeo: https://youtu.be/1glVfFxj8a4?t=3599
// Tipos de datos primitivos

// Cadenas de texto (string)
let myName = "Brais Moure"
let myName = "Brais paco2"
let alias = 'MoureDev'
let email = `braismoure@mouredev.com`

Expand Down
38 changes: 38 additions & 0 deletions Basic/02-tipodedatos.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
// String (cadena de texto)
let name = "María García"
let alias = "Rizos"
let email = "magaru91@icloud.com"

//Números
let age = 34 //entero
let height = 1.76 // Decimal

// Booleanos
let isStudent = true
let isTeacher = false

//undefined
let undefiunedValue
console.log(undefiunedValue)

//null
let nullValue = null

//Symbol
let mySymbol = Symbol ("mysymbol")

//BigInt
let myBigInt = (549687657877967674578768768454687)
let myBigInt2 = 8678967857567678768574574638796754687987857878967n

//Mostramos los tipos de datos
console.log(typeof name)
console.log(typeof alias)
console.log(typeof email)

console.log(typeof age)
console.log(typeof isTeacher)

console.log(typeof undefiunedValue)
console.log(typeof null)

106 changes: 103 additions & 3 deletions Basic/03-beginner-exercises.js
Original file line number Diff line number Diff line change
@@ -1,24 +1,124 @@
/*
Clase 18 - Ejercicios: primeros pasos
18 - Ejercicios: primeros pasos
Vídeo: https://youtu.be/1glVfFxj8a4?t=4733
*/

// 1. Escribe un comentario en una línea
// 1. Escribe un comentario en sola línea
//Hola Javascript//

// 2. Escribe un comentario en varias líneas
/*hola
javascript*/

// 3. Declara variables con valores asociados a todos los datos de tipo primitivos

//String
let myName = "María"

//Number
let age = 34
let height = 1.76
//boolean
let isTeacher = false
let isStudent = true
//Undefined
let undefinedValue = undefined
//null
let nullValue = null
//Symbol
let mySymbol = Symbol("mySymbol")
//BigInt
let myBigInt = BigInt(65789779656587974654687789679674658748967897967)
let myBigInt2 = 576878654963796796578967968746789679687879687634n

// 4. Imprime por consola el valor de todas las variables
console.log (myName)
console.log (age)
console.log (height)
console.log (isTeacher)
console.log (isStudent)
console.log (undefinedValue)
console.log (nullValue)
console.log (mySymbol)
console.log (myBigInt)
console.log (myBigInt2)

// 5. Imprime por consola el tipo de todas las variables
console.log (typeof myName)
console.log (typeof age)
console.log (typeof height)
console.log (typeof isTeacher)
console.log (typeof isStudent)
console.log (typeof undefinedValue)
console.log (typeof nullValue)
console.log (typeof mySymbol)
console.log (typeof myBigInt)
console.log (typeof myBigInt2)

// 6. A continuación, modifica los valores de las variables por otros del mismo tipo
myName = "Ana"
age = 25
height = 1.65
isTeacher = true
isStudent = false
undefinedValue = undefined
nullValue = null
mySymbol = Symbol("newSymbol")
myBigInt = BigInt(12345678901234567890)
myBigInt2 = 999999999999999999999999999n


// 7. A continuación, modifica los valores de las variables por otros de distinto tipo
myName = 123
age = "veinte y 6"
height = true
isTeacher = null
isStudent = undefined
undefinedValue = false
nullValue = true
mySymbol = 1.25
myBigInt = "12345678901234567890"
myBigInt2 = null

// 8. Declara constantes con valores asociados a todos los tipos de datos primitivos
//String
const myName2 = "Ale"
//Number
const age2 = 30
const height2 = 1.70
//boolean
const isTeacher2 = true
const isStudent2 = false
//Undefined
const undefinedValue2 = undefined
//null
const nullValue2 = null
//Symbol
const mySymbol2 = Symbol("Alex")
//BigInt
const myBigInt1 = BigInt(65789779656587974654687789679674658748967897967)
const myBigInt3 = 576878654963796796578967968746789679687879687634n

// 9. A continuación, modifica los valores de las constantes
//String
//estas líneas darían error por que no se puede redeclarar una constante
//myName = "Pepa"
//Number
//age = 49
//height = 1.50
//boolean
//isTeacher = true
//isStudent = false
//Undefined
//undefinedValue = undefined
//null
//nullValue = null
//Symbol
//mySymbol = Symbol("nuevoSymbol")
//BigInt
//myBigInt = BigInt(1234567891000012454897968545657897)
//myBigInt2 = 787897897897897897897897897897897897447141n

// 10. Comenta las líneas que produzcan algún tipo de error al ejecutarse
// 10. Comenta las líneas que produzcan algún tipo de error al ejecutarse
//no puedo redeclarar una variable con el mismo nombre en el mismo archivo
//no puedo redeclarar let o const con el mismo nombre en el mismo ámbito
2 changes: 2 additions & 0 deletions Basic/tempCodeRunnerFile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@

console.log(helloworld3)