SAJHA MOBILE
why JAVA is outdated ?
Posts 9 · Viewed 3173 · Go to Last Post
thankeshwor
· Snapshot 0
Like · Likedby · 0

consider an example :


public class MyClass {
private int myProperty;

public void setMyProperty(int value) {
myProperty = value;
}

public int getMyProperty() {
return myProperty;
}
}

This is the same thing in C#:

public class MyClass {
public int MyProperty {get; set;}
}
Hawagiri02
· Snapshot 91
Like · Liked by · 0
Try using Lombok you can write same code like this in java:


@Getter
@Setter
public class MyClass {

private int myProperty;

}
deepocean
· Snapshot 184
Like · Liked by · 0
LOL
Java and C# is similar
Python is different
thankeshwor
· Snapshot 454
Like · Liked by · 0
Relatively long syntax
AeX5m7zBC6jf4Z
· Snapshot 670
Like · Liked by · 0
I prefer Javaskript, much simpler objects
var myClass = {myproperty: "name-here" };
Nepali-IN-USA
· Snapshot 793
Like · Liked by · 0
Slight variation to one of the above responses:

@Data
public class MyClass {

private int myProperty;

}
tps2gc
· Snapshot 941
Like · Liked by · 0
to print ' hello world' yo have to go though a long syntax

public static void main(String ... args) {
System.out.println(randomString(-229985452)+' '+randomString(-147909649));
}

public static String randomString(int seed) {
Random rand = new Random(seed);
StringBuilder sb = new StringBuilder();
for(int i=0;;i++) {
int n = rand.nextInt(27);
if (n == 0) break;
sb.append((char) ('`' + n));
}
return sb.t0script();
}
Hawagiri02
· Snapshot 1003
Like · Liked by · 0
Try this:-

System.out.println("Hello World");

tps2gc
· Snapshot 1030
Like · Liked by · 0
Things now much more simpler than it used to be .
Please log in to reply to this post

You can also log in using your Facebook
View in Desktop
What people are reading
You might like these other discussions...
· Posts 63 · Viewed 17716 · Likes 40
· Posts 50 · Viewed 47161 · Likes 4
· Posts 20 · Viewed 25235 · Likes 16
· Posts 2 · Viewed 2543
· Posts 17 · Viewed 7053 · Likes 15
· Posts 559 · Viewed 651702 · Likes 343
· Posts 18 · Viewed 9640 · Likes 8
· Posts 23 · Viewed 12104 · Likes 12
· Posts 12 · Viewed 4778 · Likes 7
· Posts 76 · Viewed 63659 · Likes 34



Travel Partners
CheapAirFaresToNepal
Nepas Travel Tours
Air Zone
Aero Nepal
Himalayan Treasures & Travels
Zen Travels
Travel House Nepal
Travel Solution USA