Geeks Talk

Prepare for your Next Interview


Welcome to the Geeks Talk forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Tell me the error

This is a discussion on Tell me the error within the Java forums, part of the Software Development category; class input { public static void main(String args[]); Throws IOException; { int i; String str; BufferReaderbr=newBufferReader(newInputstreamReader(System.in)); System.out.println("enter name"); str = br.Readline() System.out.println(str); }...

Go Back   Geeks Talk > Software Development > Java
Register Blogs FAQ Tag Cloud Calendar Mark Forums Read

Java Java related Issues and Problems

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 12-29-2008
Junior Member
 
Join Date: Dec 2008
Location: delhi
Posts: 8
Thanks: 3
Thanked 1 Time in 1 Post
soniyaparjapat is on a distinguished road
Unhappy Tell me the error

class input
{
public static void main(String args[]);
Throws IOException;
{ int i;
String str;
BufferReaderbr=newBufferReader(newInputstreamReader(System.in));
System.out.println("enter name");
str = br.Readline()
System.out.println(str);
}
Reply With Quote
The Following User Says Thank You to soniyaparjapat For This Useful Post:
Sponsored Links
  #2 (permalink)  
Old 01-04-2009
Junior Member
 
Join Date: Jan 2009
Location: Andhra Pradesh, India
Posts: 1
Thanks: 0
Thanked 1 Time in 1 Post
navaneetha4ever is on a distinguished road
Re: Tell me the error

import java.io.*;
import java.util.*;

class input
{
public static void main(String args[]) throws IOException
{
//int i;
String str;
BufferedReader br= new BufferedReader(new InputStreamReader(System.in));
System.out.println("enter name");
str = br.readLine()
System.out.println(str);
}
}
Reply With Quote
The Following User Says Thank You to navaneetha4ever For This Useful Post:
  #3 (permalink)  
Old 01-05-2009
Junior Member
 
Join Date: May 2007
Location: Coimbatore
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Akilan Paul is on a distinguished road
Re: Tell me the error

InputStreamReader()
readLine()
throws
Reply With Quote
  #4 (permalink)  
Old 01-08-2009
Junior Member
 
Join Date: Jan 2009
Location: india
Posts: 4
Thanks: 0
Thanked 1 Time in 1 Post
venkatSeeni is on a distinguished road
Re: Tell me the error

the main should not end with semicolon...
class input
{
public static void main(String args[])
Throws IOException;
{ int i;
String str;
BufferReaderbr=newBufferReader(newInputstreamReader(System.in));
System.out.println("enter name");
str = br.Readline()
System.out.println(str);
}
}

the above will work.,...
Reply With Quote
The Following User Says Thank You to venkatSeeni For This Useful Post:
  #5 (permalink)  
Old 01-08-2009
Junior Member
 
Join Date: Dec 2008
Location: delhi
Posts: 8
Thanks: 3
Thanked 1 Time in 1 Post
soniyaparjapat is on a distinguished road
Re: Tell me the error

venkant seeni
there was multiple error in ur progam
like
BufferReder wil be BufferedReder
in Throws T remains small t........
in Readline R remains small r.......
and there will be a ; after readline()........
Reply With Quote
  #6 (permalink)  
Old 01-14-2009
Junior Member
 
Join Date: Jan 2009
Location: INDIA
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
axezohari is on a distinguished road
Re: Tell me the error

Throws IOException; is wrong
str = br.Readline() is wrong
Reply With Quote
  #7 (permalink)  
Old 01-15-2009
Junior Member
 
Join Date: Jan 2009
Location: pune,India
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
manvesh is on a distinguished road
Smile Re: Tell me the error

semicolon at the end of main method
'T'hrows small t,
Reply With Quote
  #8 (permalink)  
Old 01-22-2009
Junior Member
 
Join Date: Jan 2009
Location: Ahmedabad
Posts: 8
Thanks: 0
Thanked 3 Times in 2 Posts
tapan_kushwaha is on a distinguished road
Re: Tell me the error

first of dear u have to import the class file then see the semicolan u place at wrong side...
see the program.....that wiill work i am not shour....ok dont panic.....

import java.io.*;
import java.util.*;

class Input
{
public static void main(String args[]) Thorws Exception;
// int i ; ' will not come because i not in use'
String str;
BufferReader br = newBufferReader(newInputstreamReader(System.in));
System.out.println("enter name");
str = br.Readline(); // here wii come semicolon
System.out.println(str);
}
Reply With Quote
  #9 (permalink)  
Old 01-22-2009
Junior Member
 
Join Date: Jan 2009
Location: Ahmedabad
Posts: 8
Thanks: 0
Thanked 3 Times in 2 Posts
tapan_kushwaha is on a distinguished road
Re: Tell me the error

public static void main(String args[]) Thorws Exception // here also semicolon not come.....

ok dear so bye.....
Reply With Quote
  #10 (permalink)  
Old 02-09-2009
Junior Member
 
Join Date: Feb 2009
Location: pakistan hyderabad
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
AATIQ is on a distinguished road
Re: Tell me the error

ur program has error
in java we always start method name with small letter but u have declare with capital letter
str=br.ReadLine();// this is incorrect
str=br.readLine();// right way
ok thanks
public static void main(String arg[])throws IOException{
right way to declare main method

Last edited by AATIQ; 02-09-2009 at 01:16 AM.
Reply With Quote
  #11 (permalink)  
Old 02-09-2009
Junior Member
 
Join Date: Feb 2009
Location: chennai
Posts: 4
Thanks: 2
Thanked 0 Times in 0 Posts
vaas449 is on a distinguished road
Re: Tell me the error

follow the navaneetha4ever answer ..that was abstly right
Reply With Quote
  #12 (permalink)  
Old 02-09-2009
Junior Member
 
Join Date: Jan 2009
Location: bangalore
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
renuka_renukut is on a distinguished road
Re: Tell me the error

Hi

In this program u have written incorrect code , means ur program have "Syntax Error".
Reply With Quote
  #13 (permalink)  
Old 02-09-2009
Junior Member
 
Join Date: Feb 2009
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
ysurendra_7 is on a distinguished road
Re: Tell me the error

which language ru talking about ????
Reply With Quote
  #14 (permalink)  
Old 02-09-2009
Junior Member
 
Join Date: Feb 2009
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
ysurendra_7 is on a distinguished road
Re: Tell me the error

hi friend
could u tell me these questions
how to declare dynamic array?
how to declere variable?
plz tell me answers
ok
Reply With Quote
  #15 (permalink)  
Old 02-10-2009
Junior Member
 
Join Date: Feb 2009
Location: india
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
sham27khan is on a distinguished road
Re: Tell me the error

import java.io.*;
class input
{
public static void main(String args[])
throws IOException
{
int i;
String str;
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
System.out.println("enter name");
str = br.readLine();
System.out.println(str);
}
}
Reply With Quote
  #16 (permalink)  
Old 02-19-2009
Junior Member
 
Join Date: Feb 2009
Location: Amalapuram
Posts: 14
Thanks: 3
Thanked 0 Times in 0 Posts
madhoo_09 is on a distinguished road
Re: Tell me the error

please tell me about the usage of FileNameFilter interface in java.
Reply With Quote
  #17 (permalink)  
Old 02-19-2009
Junior Member
 
Join Date: Feb 2009
Location: Amalapuram
Posts: 14
Thanks: 3
Thanked 0 Times in 0 Posts
madhoo_09 is on a distinguished road
Re: Tell me the error

please explain the syntax of read and write methods in c++
Reply With Quote
  #18 (permalink)  
Old 02-20-2009
Junior Member
 
Join Date: Feb 2009
Location: Amalapuram
Posts: 14
Thanks: 3
Thanked 0 Times in 0 Posts
madhoo_09 is on a distinguished road
Thumbs up Re: Tell me the use of FileNameFillter interface

Quote:
Originally Posted by madhoo_09 View Post
Please tell me about the usage of FileNameFilter interface in java.
Reply With Quote
  #19 (permalink)  
Old 03-05-2009
Junior Member
 
Join Date: Mar 2009
Location: India
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
ganeshred is on a distinguished road
Re: Tell me the error

import java.io.*;

class input
{
public static void main(String args[])throws Exception
{
int i;
String str;
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
System.out.println("enter name");
str = br.readLine();
System.out.println(str);
}
}


Thats all
Reply With Quote
  #20 (permalink)  
Old 03-05-2009
Junior Member
 
Join Date: Mar 2009
Location: India
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
ganeshred is on a distinguished road
Re: Tell me the error

import java.io.*;

class input
{
public static void main(String args[])throws Exception
{
int i;
String str;
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
System.out.println("enter name");
str = br.readLine();
System.out.println(str);
}
}
Reply With Quote
Reply

  Geeks Talk > Software Development > Java

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
while creating a new domain error message is displayed <Unexpected Error> zubi_ste Test Director 1 10-16-2009 08:35 AM
Error -26612: HTTP Status-Code=500 (Internal Server Error) jasmine22 LoadRunner 4 11-18-2008 06:26 AM
Error: Internal error in agent - Function never returned a value sajithkutty SilkTest 6 06-02-2008 05:05 AM
Getting error "syntax error in ObjectRepository" siteuse QTP 1 07-05-2007 04:57 PM
Report Net on XP gives error, Cryptographic error has occured chandrabhoopathy1 Data Warehousing 0 05-24-2007 07:07 PM


All times are GMT -4. The time now is 08:08 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.1
Copyright © 2009 GeekInterview.com. All Rights Reserved