DEV Community

aelexa
aelexa

Posted on

3 3

Java Practice on Holidays

Today,i finally decided to be productive atleast and practice on java basics

i think this is the start of my java journey? or roadmap.

Right now im following Programiz Java Excercises

java-programming/examples

i do these exercise by not looking at the actual code thats not a flex cause i need more practice writing good variable name

01

Java Program to Print an Integer (Entered by the User)


`import java.util.Scanner;
public class RandomPractice {
    public static void main(String[] args) {        

     Scanner scan = new Scanner(System.in);

  System.out.println("Enter a number : ");
  int number = scan.nextInt();

// Concatenates String and Number entered by user 
// Prints the number you entered 
// These " " are used to separate variables in one line 
  System.out.println("You entered" + " " +number);`

INPUT  : 10 
OUTPUT : You entered 10

Enter fullscreen mode Exit fullscreen mode

Heroku

Build apps, not infrastructure.

Dealing with servers, hardware, and infrastructure can take up your valuable time. Discover the benefits of Heroku, the PaaS of choice for developers since 2007.

Visit Site

Top comments (1)

Collapse
 
aelexa profile image
aelexa • Edited

if anyone were offended in my grammar im very sorry english is not my first language
im open for any corrections in my code!

tnx

Qodo Takeover

Introducing Qodo Gen 1.0: Transform Your Workflow with Agentic AI

Rather than just generating snippets, our agents understand your entire project context, can make decisions, use tools, and carry out tasks autonomously.

Read full post

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay