Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class MyTest {
- //Do not edit the main function
- public static void main(String[] args) {
- int input;
- //Get the input
- Scanner scanner = new Scanner(System.in);
- input = scanner.nextInt();
- //Print output returned from the logic function
- System.out.println(logic(input));
- }
- //The function is expected to return an integer.
- //The function accepts an integer as parameter.
- public static int logic(int input){
- //Write your code here
- //You can create other functions and call from here
- //Don't print anything. Just return the intended output
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement