Lesson 1 of 0
In Progress

Assignment No.1 – JavaScript

Submission:

Submit all your .js files by compressing them into a ZIP folder and uploading it to the student portal. (You can make separate files or you can do the same in single JS file)

Grading Criteria:  

  • Correctness of syntax
  • Correct implementation of variable declarations, arithmetic operations, and logical conditions.
  • Clarity and cleanliness of code.

Task – No. 1

Find out if number is  prime number or not
Hint : Prime number is divisible  only by itself and 1 (e.g.  2, 3, 5, 7, 11).

Task- No. 2.

  1. Check if number is even or odd using parseint
  2. Check number is positive or negative

Task- No. 3

Check an alphabet is a vowel or not

Task- No. 4

Generate triangle output  like below,

*
* *
* * *
* * * *
* * * * *

Hint: nested  loop required

Task No. 5

Steps:

  • Create an array and fill it  with numbers
  • Ask input from user
  • Find element in array  that is provided by user

You cannot copy content of this page