Update Helloworld.java

WIP: logic
Added the Logic (1st draft)