What do you want to save?
Add Code snippet
New code examples
-
Java 2021-10-14 01:02:09
Java program to find simple interest
// Java program to find simple interest import java.util.Scanner; public class SimpleInterestJavaProgram { public static void main(String[] args) { float principal, rate, time; Scanner sc = new Scanner(System.in); System.out.print(... Add solution -
Java 2021-10-13 03:19:08
Floyd's triangle star pattern in java
// Floyd's triangle star pattern in java import java.util.Scanner; public class FloydTriangleStars { public static void main(String[] args) { Scanner sc = new Scanner(System.in); System.out.println("Enter the number of rows of floy... Add solution -
Java 2021-10-12 01:08:06
Floyd's triangle number pattern using while loop in java
// Floyd's triangle number pattern using while loop in java import java.util.Scanner; public class FloydTriangleWhileLoop { public static void main(String[] args) { Scanner sc = new Scanner(System.in); System.out.println("Enter the... Add solution -
Java 2021-10-09 03:38:07
sum of digits in java
long number, sum; Scanner sc = new Scanner(System.in); System.out.println("Enter any DIGIT number: "); number = sc.nextLong(); sc.close(); // For Logic for adding all digits in the given number for (sum = 0; number != 0; number /= 10) { sum += ... Add solution -
Java 2021-10-06 12:25:06
perimeter of parallelogram in java
import java.util.Scanner; public class PerimeterOfParallelogram { public static void main(String[] args) { Scanner sc = new Scanner(System.in); System.out.println("Please enter length of adjacent side of parallelogram: "); ... Add solution -
Java 2021-10-02 09:26:02
amstrong
//Java program to check whether a number is armstrong or notimport java.util.Scanner;public class armstrong_number_or_not{ public static void main(String[] args) { //scanner class declaration Scanner sc = new Scanner(System.in); //input from user Syst... Add solution -
Java 2021-10-01 20:34:07
Java program to check palindrome string using recursion
import java.util.Scanner; public class RecursivePalindromeJava { // to check if string is palindrome using recursion public static boolean checkPalindrome(String str) { if(str.length() == 0 || str.length() == 1) return true; ... Add solution -
Java 2021-09-30 14:00:02
Java program to check palindrome number using recursion
import java.util.Scanner; public class RecursivePalindromeJava { // to check if string is palindrome using recursion public static boolean checkPalindrome(String str) { if(str.length() == 0 || str.length() == 1) return true; ... Add solution
Best helpers
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5