Write a program to find the number and sum of all integers from 100 to 300 that are divisible by 11
#include<stdio.h>
#include<iostream.h> #include<conio.h> void main() { for(int i=1;i<=10;i++) { cout<<i*i; } getch(); }
for two positive integers: public static int gcd(int i1, int i2) { // using Euclid's algorithm int a=i1, b=i2, temp; while (b!=0) { temp=b; b=a%temp; a=temp; } return a; }
Both compiler and interpreter are the language programs that translates source program into machine code or we can say object code. Both are used to find errors in source program.
Write a program to find the grade obtained by the students of a class
To find the average of integers, add them all together then divide the total by the number of integers.
It is between 4 and 5.
Subtract the smaller from the larger.
None
The integers between 2.09 and 15.3 are 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, and 15. So there are 13 integers between 2.09 and 15.3.
To find the distance between two integers using the difference, you simply subtract the smaller integer from the larger integer. The result will be the distance between the two integers on the number line. For example, if you have integers 7 and 3, you would subtract 3 from 7 to get a distance of 4. This method works because the difference between two integers gives you the number of units separating them on the number line.
For each pair of such integers, find the difference between the absolute values of the two integers and allocate the sign of the bigger number to it.
The question makes no sense.. you can easily find the sum of integers between 1 and 300 but what does 11 or 13 have to do with it.
-- write the difference between the integers without regard to their signs -- give the difference the same sign as the larger of the two integers
To find the total number of integers between 100 and 300 that are divisible by 3, we first determine the smallest and largest integers in this range that are divisible by 3. The smallest integer divisible by 3 is 102, and the largest is 297. To find the total number of integers between 102 and 297 that are divisible by 3, we calculate (297-102)/3 + 1, which equals 66. Therefore, there are 66 integers between 100 and 300 that are divisible by 3.
8 and 9
9