Grepper Logo

what is the output of the following code if the input is : 5 10 ? scanner s = new scanner(system.in); int a = s.nextint(); int n = s.nextint(); system.out.println(a+b);

Technical Problem Cluster First Answered On August 16, 2022 Popularity 6/10 Helpfulness 3/10

Contributions From The Grepper Developer Community

Contents

Code Examples

  • Scanner s = new Scanner(System.in); String str = s.next(); int a = s.nextInt(); System.out.print(str + " " + a);

  • Related Problems

  • what is the output of the following code if the input is : 5 10 ? scanner s = new scanner(system.in); int a = s.nextint(); int n = s.nextint(); system.out.println(a+b);
  • java scanner next
  • scanner int
  • java scanner nextint
  • scanner.nextline is one behind
  • initialize scanner java
  • scanner in jasmin
  • java scanner nextline
  • how to instantiate a scanner in java
  • import java.util.scanner;

  • TPC Matrix View Full Screen

    Scanner s = new Scanner(System.in); String str = s.next(); int a = s.nextInt(); System.out.print(str + " " + a);

    0
    Popularity 6/10 Helpfulness 3/10 Language java
    Source: Grepper
    Tags: int java s string
    Link to this answer
    Share Copy Link
    Contributed on Aug 16 2022
    george walton
    1 Answers  Avg Quality 5/10


    X

    Continue with Google

    By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
    X
    Grepper Account Login Required

    Oops, You will need to install Grepper and log-in to perform this action.