Java Stdin and Stdout I

Sort by

recency

|

591 Discussions

|

  • + 0 comments

    public class Solution {

    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int a = scan.nextInt();
        int b = scan.nextInt();
        int c = scan.nextInt();
        scan.close();
    
        System.out.println(a);
        System.out.println(b);
        System.out.println(c);
    
    }
    

    }

  • + 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 n1 = sc.nextInt();
            int n2 = sc.nextInt();
            int n3 = sc.nextInt();
            
            sc.close();
            
            System.out.println(n1);
            System.out.println(n2);
            System.out.println(n3);
        }
    }
    
  • + 0 comments

    public static void main(String[] args) { Scanner sc= new Scanner(System.in); int a=sc.nextInt(); int b=sc.nextInt(); int c=sc.nextInt(); System.out.println(a); System.out.println(b); System.out.println(c); sc.close(); }

  • + 0 comments

    While practicing this Java I/O challenge, I was also checking different resources. I found a blog (https://fashionismic.com) where alongside lifestyle content, there were some notes that touched on Java basics. Surprising mix — but interesting! Has anyone else come across lifestyle sites adding coding sections?”

  • + 0 comments

    import java.io.; import java.util.;

    public class Solution {

    public static void main(String[] args) {
        /* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */
        Scanner sc= new Scanner(System.in);
        int a=sc.nextInt();
        int b=sc.nextInt();
        int c=sc.nextInt();
        System.out.println(a);
            System.out.println(b);
                System.out.println(c);
        sc.close();
    }
    

    }