SAJHA MOBILE
why JAVA is outdated ?
Posts 9 · Viewed 3428 · 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 4 · Viewed 356 · Likes 1
· Posts 2 · Viewed 65
· Posts 4 · Viewed 407 · Likes 2
· Posts 33 · Viewed 2799 · Likes 53
· Posts 3 · Viewed 536
· Posts 1 · Viewed 45
· Posts 1 · Viewed 105
· Posts 1 · Viewed 16
· Posts 3 · Viewed 678
· Posts 4 · Viewed 273



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