Question: Given the following code segment: Buffered Reader stdin = new BufferedReader (new inputstreamreader (System.in)); String temp = stdin.readline (); String partl = temp substring(0, temp.indexof());

Given the following code segment: Buffered Reader stdin = new BufferedReader (new inputstreamreader (System.in)); String temp = stdin.readline (); String partl = temp substring(0, temp.indexof()); String part 2 = temp.sub string(temp.indexof ('s')); temp = (part2 + ", " + part1 + " " + temp.length()); System.out.println (temp) is output when the input is Snuffy Smith
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
