Skip to content

A collection of JavaScript exercises focused on mastering the for loop. This repository includes various examples of loops performing calculations, generating sequences, and solving numeric problems such as factorials, sums, and multiples.

Notifications You must be signed in to change notification settings

ferrnd/javascript-for-loops

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔁 JavaScript For Loop Exercises

A collection of JavaScript examples and mini-programs that use the for loop to solve different numeric problems and sequences.

📂 Contents

Each file demonstrates a different use case of the for loop:

  • Calcular_a_soma_dos_numeros_de_1_a_N.js → Calculates the sum of numbers from 1 to N.
  • Calcular_o_fatorial_de_um_numero_6.js → Calculates the factorial of a given number.
  • Calcular_o_quadrado_dos_numeros_de_1_a_15.js → Displays the square of numbers from 1 to 15.
  • Contar_quantos_numeros_divisiveis_por_3_existem.js → Counts how many numbers are divisible by 3.
  • Imprimir_numeros_de_1_a_50.js → Prints numbers from 1 to 50.
  • Imprimir_numeros_impares_de_1_a_99.js → Prints odd numbers from 1 to 99.
  • Imprimir_numeros_pares_de_0_a_100.js → Prints even numbers from 0 to 100.
  • Imprimir_numeros_regressivos_de_N_a_1.js → Prints a countdown from N to 1.
  • Imprimir_os_multiplos_de_5_entre_5_e_50.js → Prints multiples of 5 between 5 and 50.
  • Imprimir_sequencia_-10_-9_-8.js → Prints a custom decreasing sequence.

🎯 Learning Goals

  • Practice repetition structures with for
  • Improve logical thinking with iterative algorithms
  • Understand control flow and number iteration in JavaScript

🛠️ Technologies Used

  • Language: JavaScript

About

A collection of JavaScript exercises focused on mastering the for loop. This repository includes various examples of loops performing calculations, generating sequences, and solving numeric problems such as factorials, sums, and multiples.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published