{"id":1086,"date":"2022-02-07T18:42:42","date_gmt":"2022-02-07T18:42:42","guid":{"rendered":"https:\/\/mdr.foobrdigital.com\/?p=1086"},"modified":"2022-02-07T18:42:42","modified_gmt":"2022-02-07T18:42:42","slug":"basic-syntax","status":"publish","type":"post","link":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/2022\/02\/07\/basic-syntax\/","title":{"rendered":"Basic Syntax"},"content":{"rendered":"\n<p>About Java programs, it is very important to keep in mind the following points.<\/p>\n\n\n\n<ul><li><strong>Case Sensitivity<\/strong>&nbsp;\u2212 Java is case sensitive, which means identifier&nbsp;<strong>Hello<\/strong>&nbsp;and&nbsp;<strong>hello<\/strong>&nbsp;would have different meaning in Java.<\/li><li><strong>Class Names<\/strong>&nbsp;\u2212 For all class names the first letter should be in Upper Case. If several words are used to form a name of the class, each inner word&#8217;s first letter should be in Upper Case.<strong>Example:<\/strong>&nbsp;<em>class MyFirstJavaClass<\/em><\/li><li><strong>Method Names<\/strong>&nbsp;\u2212 All method names should start with a Lower Case letter. If several words are used to form the name of the method, then each inner word&#8217;s first letter should be in Upper Case.<strong>Example:<\/strong>&nbsp;<em>public void myMethodName()<\/em><\/li><li><strong>Program File Name<\/strong>&nbsp;\u2212 Name of the program file should exactly match the class name.When saving the file, you should save it using the class name (Remember Java is case sensitive) and append &#8216;.java&#8217; to the end of the name (if the file name and the class name do not match, your program will not compile).But please make a note that in case you do not have a public class present in the file then file name can be different than class name. It is also not mandatory to have a public class in the file.<strong>Example:<\/strong>&nbsp;Assume &#8216;MyFirstJavaProgram&#8217; is the class name. Then the file should be saved as&nbsp;<em>&#8216;MyFirstJavaProgram.java&#8217;<\/em><\/li><li><strong>public static void main(String args[])<\/strong>&nbsp;\u2212 Java program processing starts from the main() method which is a mandatory part of every Java program.<\/li><\/ul>\n","protected":false},"excerpt":{"rendered":"<p>About Java programs, it is very important to keep in mind the following points. Case Sensitivity&nbsp;\u2212 Java is case sensitive, which means identifier&nbsp;Hello&nbsp;and&nbsp;hello&nbsp;would have different meaning in Java. Class Names&nbsp;\u2212 For all class names the first letter should be in Upper Case. If several words are used to form a name of the class, each [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[238],"tags":[],"_links":{"self":[{"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/posts\/1086"}],"collection":[{"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/comments?post=1086"}],"version-history":[{"count":0,"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/posts\/1086\/revisions"}],"wp:attachment":[{"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/media?parent=1086"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/categories?post=1086"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mudassirbackup.infinitycodestudio.com\/index.php\/wp-json\/wp\/v2\/tags?post=1086"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}