What do you want to save?
Add Code snippet
New code examples
-
Java 2022-03-17 02:05:01
java accept 2 integers from the user, and using a method add these numbers and print the result
static void M1(int num1, int num2) { int sum = num1 + num2; System.out.println("sum of " + num1 + " and " + num2+ " = " + sum); } public static void main(String[] args) { // using Methods... Add solution -
TypeScript 2021-11-16 17:42:16
adding elements in a specified column or row in a two dimensional array java
package multidimensionalarrays; public class MultidimensionalArrays { public static void main(String[] args) { double sumOfRow = 0; double[][] matrix = new double[3][4]; java.util.Scanner input = new java.util.Scanner(System.... Add solution -
Java 2021-10-22 04:35:10
Java program to check even or odd number
import java.util.Scanner; class CheckEvenOdd { public static void main(String args[]) { int num; System.out.println("Enter an Integer number:"); //The input provided by user is stored in num Scanner input = new Scanner(Syst... Add solution -
Java 2021-10-10 16:56:04
why are my if statements not working with inputs in java
//it does not seem to work for me with using the double equal sign in //the if statement (==). Instead, try this. Scanner input = new Scanner(System.in); System.out.print("This is the user's input prompt: "); var userInput = input.next(); i... Add solution -
Java 2021-10-09 19:04:06
java program to search item from name in class
import java.io.File; import java.io.FileNotFoundException; import java.util.* public class Catalog{ private static int MAX_ITEMS = 10; private Products[] list; private int nextItem; /** * Default constructor */ publi... Add solution
Best helpers
+5
+5
+5
+5
+5
+5
+5
+5
+5