Skip to content

Commit ecaffd7

Browse files
Add files via upload
New language Java snippets
1 parent 492a306 commit ecaffd7

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

snippets/java/basics/hello-world.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
title: Hello-World
3+
description: Prints Hello world in the console
4+
author: SarvariHarshitha
5+
tags: java, console, printing
6+
---
7+
8+
```java
9+
// This is the main class of the Java program
10+
public class Main {
11+
// The main method is the entry point of the program
12+
public static void main(String args[]) {
13+
// This statement prints "Hello, World!" to the console
14+
System.out.println("Hello, World!");
15+
}
16+
}
17+
18+
```

snippets/java/icon.svg

Lines changed: 2 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)