
how do i get a java program to take an input from the user and have it terminate by a period and not by pressing enter?

How to get the input for java programs
public class name{ public static void main(String args[]){ Scanner fi=new Scanner(system.in); BufferReader bf=new BufferReader(fi); int a=bf.readLine(); system.out.println("Value OF input is"+a) } }
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.