Asked:
16 minutes ago

More new questions »

Answered

In Technology

import java.io.*; class ReverseNumber { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); …System.out.println("Enter Number"); int num= Integer.parseInt(br.readLine()); int n=num; int rem=0; int rev=0; while(n!=0) { rem = n%10; rev = rev*10+rem; n=n/10; } System.out.println("Reverse Number : " + rev); } } (MORE)

Answered

The do-while loop is a looping structure. This looping structure is an exit controlled loop. that means the loop executes at-least once before the test expression is checked. … The general form of do-while loop is: do { statement1 statement2 } while (expression) (MORE)

Answered

In Technology

#include #include void main() { int abcd; printf("enter a 4-digit no."); scanf("%d",&abcd); a=abcd/1000; abcd=abcd%1000; b=abcd/100; abcd=abcd%100; c=abc…d/1o; abcd=abcd%10; d=abcd; printf("reverse=%d",dcba); getch(); } (MORE)

Answered

In Technology

include void main() { int no,rem=0,sum=0,n; /*declaration*/ printf("Enter 2 digit number:"); scanf("%d",&no); for(n=1;n… (MORE)

Answered

In Technology

Answer for(i=0, i… (MORE)

Answered

In Uncategorized

the 5s because it has better service but it dosent have diffrent colrs just silver gold and black

Answered

In Technology

include #include void main() { int num,num_save; int ar[5],i=0,res_e=0,res_o=0; printf("\\nEnter the number : "); scanf("%d",&num); num_save=num; while(num_s…ave>0) { ar[i]=num_save%10; num_save/=10; i++; } i--; while(i>=0) { if(ar[i]%2==0) res_e=res_e+ar[i]; else res_o=res_o+ar[i]; } printf("\\nNumber is %d\\n",num); printf("\\nSum of even digits is %d",sum_e); printf("\\nSum of odd digits is %d",sum_o); getch(); } (MORE)

Answered

20c + 5 = 5c + 65 Divide through by 5: 4c + 1 = c + 13 Subtract c from both sides: 3c + 1 = 13 Subtract 1 from both sides: 3c = 12 Divide both sides by 3: c = 4

Answered

In Technology

Function sum_odd_digits(ByVal number As Integer) As Integer Dim digit As Integer sum_odd_digits = 0 While number 0 digit = number Mod 10 If digi…t And 1 Then sum_odd_digits = sum_odd_digits + digit number = number / 10 End While End Function (MORE)

Answered

In Technology

include // defines CHAR_BIT #include // defines pow() #include // defines printf() bool is_armstrong (const int n, const int b=10) { // Ret…urns true if n base b is narcissistic. // Preconditions: n>=0, b>=2 int digit[sizeof (int) * CHAR_BIT]; // caters for all digits in all bases int i, j, k; // local variables i = 0; // count of digits (so far) j = n; while (j) { digit[i] = j%b; // store least significant digit j/=b; // shift-right by one digit ++i; // increment count } k = 0; // sum of all digits raised to the power of i for (j=0; j (MORE)