Sort by

recency

|

1443 Discussions

|

  • + 0 comments

    For Java15 Platform

    I wrote the code from scratch just to get more practice

    import java.util.Scanner;
    
    class Solution
    {
        public static void main(String args[])
        {
            Scanner sc = new Scanner(System.in);
            int N = sc.nextInt();
            sc.close();
            
            for(int i=1; i<=10; i++)
            {
                System.out.println(N + " x " + i + " = " + N*i);
            }
        }
    }
    
  • + 0 comments

    import java.io.; import java.math.; import java.security.; import java.text.; import java.util.; import java.util.concurrent.; import java.util.regex.*;

    public class Solution { public static void main(String[] args) throws IOException { BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in));

        int n = Integer.parseInt(bufferedReader.readLine().trim());
        for(int i=1; i<=10; i++){
            System.out.printf("%d x %d = %d%n",n,i,n*i);
    
        }
    
        bufferedReader.close();
    }
    

    }

  • + 0 comments

    public class Solution { public static void main(String[] args) throws IOException { BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in));

        int N = Integer.parseInt(bufferedReader.readLine().trim());
        int i = 1;
        while(i<11){
        System.out.println(String.valueOf(N)+" x "+String.valueOf(i)+" = "+String.valueOf(N*i)); 
            i++;
        }
        System.out.println();
    
        bufferedReader.close();
    }
    

    }

  • + 0 comments

    public class Solution { public static void main(String[] args) throws IOException { BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in));

        int N = Integer.parseInt(bufferedReader.readLine().trim());
        int i = 1;
        while(i<11){
        System.out.println(String.valueOf(N)+" x "+String.valueOf(i)+" = "+String.valueOf(N*i)); 
            i++;
        }
        System.out.println();
    
        bufferedReader.close();
    }
    

    }

  • + 0 comments

    1.for(int i=1;i<=10;i++){ 2. System.out.println(N+" "+"x"+" "+i+" "+"="+" "+ N*i);