Compare commits

...

6 Commits

Author SHA1 Message Date
Sachin Sharma
e3cd222019 Merge 9b11949b91 into 10872e02d1 2024-06-13 17:28:34 +00:00
Julien Le Coupanec
10872e02d1 Merge pull request #385 from WPRobson/master
add docker init command to docker cheatsheet
2024-06-07 23:35:19 +02:00
Julien Le Coupanec
365b4f72b7 Merge pull request #390 from MagedMohamedTurk/patch-1
Update C.txt
2024-06-07 23:34:57 +02:00
Maged Turkoman
0f74ebe37b Update C.txt 2024-06-01 09:07:47 +03:00
Will Robson
bf4c0379f2 add docker init command to docker cheatsheet 2024-05-12 20:01:26 +01:00
Sachin-2206
9b11949b91 Some changes and more about advance java
1. Write a method of printing;
2. Write about constructor and give a example;
3. Write about advance java
2023-01-04 17:29:51 +05:30
3 changed files with 17 additions and 1 deletions

View File

@@ -149,6 +149,7 @@ Operators
^= bitwise exclusive or and store
|= bitwise or and store
, separator as in ( y=x,z=++x )
; statement terminator.
Operator precedence

View File

@@ -77,6 +77,7 @@ a \|= b; //a is the variable name; b is the variable name; this expression is an
System.out.print(String s) //print s
System.out.println(String s) //print s, followed by a newline
System.out.println() //print a newline
System.out.printf() //use %d for print integer, %c for char, use %f for float, use %s for string
```
### PARSING COMMAND-LINE ARGUMENTS
@@ -386,6 +387,12 @@ class MyClass extends MySuperClass implements YourInterface {
* A class contains constructors that are invoked to create objects from the class blueprint.
* Constructor declarations look like method declarations—except that they use the name of the class and have no return type
* Each and every class has defualt No-args constructor.
* constructor can also be override by giving the argumentsto it.
**Example:**
class constructor{
public constructor(){//the constructor name is same as of class name and it does not have any return type
System.out.println("I am a constructor");
}
```java
@@ -648,3 +655,11 @@ public class Queue<Item> implements Iterable<Item> {
boolean contains(Key key) //return if the key is in the set
int size() //number of elements in set
```
## ADVANCE JAVA
There are some advance topic in java which done the work very easy and relieable.
**Collection Framework**
It include-:
1.Arraylist
2.Set
3.Stack
4.Harshmap

View File

@@ -2,7 +2,7 @@
# DOCKER
##############################################################################
docker init # Creates Docker-related starter files
docker build -t friendlyname . # Create image using this directory's Dockerfile
docker run -p 4000:80 friendlyname # Run "friendlyname" mapping port 4000 to 80
docker run -d -p 4000:80 friendlyname # Same thing, but in detached mode