Skip to content

Instantly share code, notes, and snippets.

@smamran
Created September 20, 2015 09:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save smamran/0bd8e0d39a1ea2ee527b to your computer and use it in GitHub Desktop.
Save smamran/0bd8e0d39a1ea2ee527b to your computer and use it in GitHub Desktop.
Operating System and Architecture detection i java code.
package com.netcse.java;
public class Main {
private static final String OS_NAME = System.getProperty("os.name").toString();
public static void main(String[] args) {
System.out.println("Hello world java programming in this world is nothing but java");
System.out.println(OS_NAME);
System.out.println(System.getProperty("os.arch").toString());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment