- Create a new project in Android Studio.
- In the MainActivity.java file, add the following code:
- Replace the number 5 in the int num = 5; line with the desired input number.
- Run the app and you should see "Hello World" displayed in a Toast message that many times, depending on the input number.