Week 2 Solution

$30.00

Category: Tag:

Description

Objective: To understand the basic concepts of variable, decision and loop control statements.

Assignments:

  1. Write a Java program to check whether a number is Buzz or not.

  1. Write a Java program to calculate factorial of 12.

  1. Write a Java program for Fibonacci series.

  1. Write a Java program to reverse a number.

  1. Admission to a professional course is subject to the following conditions:

(a) marks in Mathematics >= 60

(b) marks in Physics

>=50

(c) marks in Chemistry>=40

(d) Total in all 3 subjects

>=200

(Or)

Total in Maths & Physics>=150

Given the marks in the 3 subjects of n (user input) students, write a program to process the applications to list the eligible candidates.

  1. Write a Java program to find all roots of a quadratic equation.

  1. Write a Java program to calculate the sum of natural numbers up to a certain range.

  1. Write a Java program to print all multiple of 10 between a given interval.

  1. Write a Java program to generate multiplication table.

  1. Write a Java program to find HCF of two Numbers.

  1. Write a Java program to find LCM of two Numbers.

  1. Write a Java program to count the number of digits of an integer.

  1. Write a Java program to calculate the exponential of a number.

  1. Write a Java program to check whether a number is palindrome or not.

  1. Write a Java program to check whether a number is prime or not.

  1. Write a Java program to convert a Binary Number to Decimal and Decimal to Binary.

  1. Write a Java program to find median of a set of numbers.

  1. Write a program to compute the value of Euler’s number that is used as the base of natural logarithms. Use the following formula.

e= 1+ 1/1! +1 /2! + 1/3+……………. 1/n!

  1. Write a Java program to generate all combination of 1, 2, or 3 using loop.

  1. Write a Java program to read two integer values m and n and to decide and print whether m is multiple of n.

  1. Write a Java program to display prime numbers between a given interval.

  1. Write a Java program to check whether a given number is Armstrong Number or not.

Write Java programs for the patterns given bellow: (23-25)

  1. 1

2 3 4

56789

1

2 1 2

32123

4321234

25.1 1

  1. 2

3 3

4


error: Content is protected !!