uz
Feedback
JAVA PROGRAMMING

JAVA PROGRAMMING

Kanalga Telegram’da o‘tish

Hello! I am @imabhi3030 and welcome to the Coding channel! Here we can learn all things related to coding and improve our skills. I am always present to help you. If you need any kind of assistance, just let me know! 😊

Ko'proq ko'rsatish
5 030
Obunachilar
+324 soatlar
Ma'lumot yo'q7 kunlar
+2330 kunlar
Postlar arxiv
//#4 Declaring & iniitializing Array
public class MyClass {
  public static void main(String args[]) {
     
     int arr[]; //declaring array
     arr = new int[20]; // allocating memory
  
     arr[0]= 55; //iniitializing first element
     arr[1]= 33; //initi.... 2nd Element
     System.out.println(arr[0]);
  }
}

Subscribe our channel for termux hacking,python animation,coding,html ,telegram bot tips & trick related - 👉 https://youtube.com/@CODEBOMBS Subscribe our channel for termux hacking, designing, tips & trick, bot making related - 👉 https://youtube.com/@TECHINDNN

Kya abhi bhi Google pe hi search krte ho 😒 Smart bniye use kijiye hmara Chatgpt telegram bot 👉 @imabhiAI_bot ✅ unlimited message ✅ 24×7 Support ✅ support all languages ✅ translation features ✅ quick response ✅ easy to use Our other bot you can try Compiler bot advance - @IOCompiler_bot Code compiler - @Cmpbbot Compiler pro - @CodeCompiler_Bot Solve maths - @mathsrobot Group/channel manage - @Myhurthearts_bot

Program with use of switch case to find a months public class Example{ public static void main(String args[]){ int month= 7; switch(month){ case 1 : System.out.println("january"); break; case 2: System.out.println("february"); break; case 3: System.out.println("march"); break; case 4: System.out.println("april"); break; case 5: System.out.println("may"); break; case 6: System.out.println("june"); break; case 7: System.out.println("july"); break; case 8: System.out.println("august"); break; case 9: System.out.println("september"); break; case 10: System.out.println("October"); break; case 11: System.out.println("november"); break; case 12: System.out.println("december"); break; default: System.out.println("not valid"); } } } Output: july

here's a sample Java program that computes the factorial of a given integer using recursion: public class FactorialExample { public static void main(String[] args) { int num = 5; // the number whose factorial is to be found int factorial = calculateFactorial(num); System.out.println("The factorial of " + num + " is " + factorial); } public static int calculateFactorial(int num) { if (num == 0) { return 1; } else { return num * calculateFactorial(num - 1); } } }

Program to add two numbers by accepting input from the user: ---------------------------------------------------- Program: import java.util.Scanner; public class AddTwoNumbers { public static void main(String[] args) { Scanner input = new Scanner(System.in); // Prompt the user to enter the first number System.out.print("Enter the first number: "); int num1 = input.nextInt(); // Prompt the user to enter the second number System.out.print("Enter the second number: "); int num2 = input.nextInt(); // Add the two numbers int sum = num1 + num2; // Display the result System.out.println("The sum of " + num1 + " and " + num2 + " is " + sum); } } ---------------------------------------------------- #basicprograms

Program to add two numbers ------------------------------------------------- Program: import java.util.Scanner; public class AddTwoNumbers { public static void main(String[] args) { // Create a Scanner object to read input from the user Scanner scanner = new Scanner(System.in); System.out.print("Enter the first number: "); // Read the first number from the user double num #basicprograms

Program to print hello world in java public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }

------------------------------ Introducing myself : ------------------------------ I'm also a student like you studying BCA 3rd year, I started this channel to share the knowledge of C programming . I try to gather as much programs as I can and share them with you, hoping you will support the channel by sharing this channel with your friends who are aiming to practice programs. Channel link is here👇 https://t.me/Java_language_programming If I make any mistakes in any program message me the mistake I had made so I'll try to correct them. contact here 👇 @imabhi3030