SLC S22 Week1 || Getting Started with Java and Eclipse
Assalam o Alaikum Everyone I hope all of you are fine and happy in your life. Here is my participation in the steemit contest. This is week 1 participation. This contest was organised by @kouba01. The contest is about learning a java programming language. #steemexclusive
- Task 1
JDK (Java Development Kit)
A software development tool used to create Java program applications.
Key Features:
Javac is a Java programming language compiler that reads source files written in the Java programming language and compiles them into bytecode class files.
Javadoc is documentation generated for Java programming language.
JRE (Java Runtime Environment)
JRE also known as Java RTE. This provide the minimum requirement for executing java applications.
It includes the JVM and libraries for running Java applications. It does not include development tools like a compiler. End users use it to run Java applications.
JVM (Java Virtual Machine)
Virtual Machine responsible for running Java bytecode. It converts bytecode into machine code for othe perating systems. And handle garbage collection and memory settlement.
Interdependence:
The JDK contains the JRE along with development tools.
The JRE contains the JVM that is responsible for executing Java applications.
The JVM is responsible for executing the encoded Java bytecode produced by a compiler within a JDK.
Created with canva.
- Task 2
I search on google JDK download. Then go first link oracle.
After downloading when I clink on setup the first look is there. Then select the location Where I install this. It takes hardly one minute to complete installation.
Clieck on Edit environment on start program. Then you will see path click on it and edit it. Just copy you path where you install java. mine is this. C:\Program Files\Java\jdk-23\bin. Save this path on the environment.
After save it. Then go to CMD search java --version. You will get your version.
Install Eclipse
Here is an envirment when I click on install button. we are installing for java so we click 1 IDE for java.
Then it will ask for lastest version and location.
Here is first look.
- Task 3
here is first sum 100 integer code in class sum. This is simple code. Just take for loop to load 1 to 100 integer. Then sum on every number.
- Task 4
Here is new code with complete running. I use if conditions to make it all.
Answer is right 5550 tax.
- Task 5
This is 5th task that conversion. The main is conversion if the letter is lower case my code will convert into uppercase. and same for upper case. But only those I have ipput on my code like in if else conditions. and The last thing is when 1 is not a latter. These all are hard codded.
- Task 6
The class is named ArrayOperations and the main logic of the program. Mkae integer Array. First check if array length is zero then display array is empty. The there are two methods for find largest number and sum of all number. Calls the method sortArray(array) to sort the array in ascending order. Arrays.toString(): Converts the sorted array.
Thank you reading this blog. All the task have done. Twiter is banned in Pakistan so I cannot share on Twitter. Thank you so much for reading this blog. I invite @ammar2021,@teukuipul87 and @isha-rehman to participate in this contest.
Wow, you seem to be proficient in java programs, I see you have really presented the material well about the explanation of JDK, JRE and JVM. Not that I, you have provided clear steps until the installation of the Java program can run well to complete the 6 tasks given by Prof. Kouba01. Good luck my friend.