package Lessons;
import java.util.Scanner;
public class Math {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
System.
Calling s.nextInt()
reads the next int, but does not read the new line character after that. So the new line would be read on line 15. If you are sure that every input will be put in a separate line, then you can resolve this problem by putting an extra s.nextLine()
before line 15:
...
System.out.print(" Now enter ur operator ");
s.nextLine();
String b1 = s.nextLine();
...