Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #22617

Input from Console

Newsgroups comp.lang.java.programmer
Date 2013-02-28 06:28 -0800
Message-ID <c9d678fe-b7f0-4757-8d4c-ea7454f8b2fb@googlegroups.com> (permalink)
Subject Input from Console
From subhabangalore@gmail.com

Show all headers | View raw


Dear Group,

I am trying to learn Java. I was trying to write a code for input from Console.

I found two ways to do it. One is by using import java.io.*; and the other is,
import java.util.Scanner;

If I assign a class name and start the console input from public static void main
both works fine.

But as I want to declare one function for it and like to call it in main body.

I am not being able to do that.

If any one of the learned members can kindly suggest it.

Regards,
Subhabrata. 

Back to comp.lang.java.programmer | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Input from Console subhabangalore@gmail.com - 2013-02-28 06:28 -0800
  Re: Input from Console Arne Vajhøj <arne@vajhoej.dk> - 2013-02-28 09:34 -0500
    Re: Input from Console subhabangalore@gmail.com - 2013-02-28 06:47 -0800
      Re: Input from Console FredK <fred.l.kleinschmidt@gmail.com> - 2013-02-28 07:32 -0800
      Re: Input from Console markspace <markspace@nospam.nospam> - 2013-02-28 08:42 -0800
  Re: Input from Console Roedy Green <see_website@mindprod.com.invalid> - 2013-02-28 07:44 -0800
    Re: Input from Console subhabangalore@gmail.com - 2013-02-28 08:21 -0800
    Re: Input from Console Arne Vajhøj <arne@vajhoej.dk> - 2013-02-28 16:55 -0500

csiph-web