Math, asked by narendarcorbett201, 2 months ago

1. The number of numbers which are
multiples of both 3 and 5 in the first 100
natural numbers is
DINV 2019)​

Answers

Answered by sayan3817
0

Step-by-step explanation:

// Compile this java program in any IDE such as Bluej or Eclipse or notepad to find the number of multiples of both 3 and 5 in first 100 natural numbers

class Multiples

{

public static void main()

{ int c=0;

for(int i=1;i<=100;i++)

{

if(i%3;== 0 && i%5 == 0)

c++;

}

System.out.println("Number of numbers of multiples of both 3 and 5 are "+c );

}

}

However,

the number that are multiples of 3 and 5 are muliples of 15;

Therefore the number of multiples of 3 and 5 under 100 are {15;30;45;60;75;90}

Hence, there are 6 such numbers under 100.

Answered by astitva81
1

Answer:

jsjshsnsLshss0sauaoa ou hl zhzhzlzos joh hi jzgzzJd6duxjd8sud in skzkzh

Similar questions