Computer Science, asked by prakritijoshi2005, 8 months ago

input any 10 numbers and print the sum of even and odd numbers in java without array​

Answers

Answered by anshul678996
0

public class Sum_Odd_Even

Answered by Atul05
3

The program output is also shown below.

  • The program output is also shown below.public class Sum_Odd_Even.
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.System. out. print("Enter the number of elements in array:");
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.System. out. print("Enter the number of elements in array:");n = s. nextInt();
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.System. out. print("Enter the number of elements in array:");n = s. nextInt();int[] a = new int[n];
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.System. out. print("Enter the number of elements in array:");n = s. nextInt();int[] a = new int[n];System. out. println("Enter the elements of the array:");
  • The program output is also shown below.public class Sum_Odd_Even.int n, sumE = 0, sumO = 0;Scanner s = new Scanner(System.System. out. print("Enter the number of elements in array:");n = s. nextInt();int[] a = new int[n];System. out. println("Enter the elements of the array:");for(int i = 0; i < n; i++)
Similar questions