How to take input from user in Java | Learn Coding

preview_player
Показать описание
Java Full Course for Beginners...!👇👇

Please Like | Share | SUBSCRIBE our Channel..!
Learn Coding
🙏🙏🙏

Like our Facebook Page...!
Learn Coding

Don't forget to tag our Channel...!
#ScannerClassInJava
#IOinJava
#LearnCoding
#ask4help
#TakeInputFromUserInJava
#gettinginputfromuserinjava
#GetUserInputInJava
#JavaProgramming
#InputInJava
#OutputInJava
Рекомендации по теме
Комментарии
Автор

sir aap jo bolte ho starting mai " java sikhne ke liye learn coding ko subscribe kare" mera humble request hai please ye matt bole ..boring lagta hai...otherwise you are fabulous teacher .and way of teaching is very understable.

randheeropedia
Автор

class name should not start with small letter. Use Pascal Naming Convention for class, camel for method.

ritampramanik
Автор

I am a beginner in this field...so can you explain what is the use of scanner class...and isase pehle ek video me apne bataya tha ki "static" use karenge to object create karne ki jarurat nahi, par yaha pe static bhi hai aur object bhi... please explain

subodhkadam
Автор

Sir kindly provide the pdf of ur notes

himanshiagrawal
Автор

How to run in mobile using bufferreader

techweb
Автор

Sir aap kon sa laptop/desktop use krte ho?

Princesingh_
Автор

i write this :
class elegchoscharactira
{
public static void main(String args[])
{
char x;
scanner smth = new scanner(System.in);
System.out.println("grapse enan charactira: ");
x=smth.next();
System.out.println(x);


}
}
but something goes wrong in onlinegbd. could you help me?
it writes this :
Main.java:15: error: cannot find symbol
scanner smth = new scanner(System.in);
^
symbol: class scanner
location: class elegchoscharactira
Main.java:15: error: cannot find symbol
scanner smth = new scanner(System.in);
^
symbol: class scanner
location: class elegchoscharactira
2 errors

ΧΡΥΠΟΥ
Автор

Sir why you took a+ +b in the last line

gjagadeeshwar
Автор

when I m adding scanner without adding import java.util it is showing error

sadiyakhan
Автор

import java.util.Scanner;
class Test
{
/*java variable*/

public static void main(String args[])
{
int a;
String b;
System.out.println("enter a data");
Scanner obj=new Scanner(System.in);

a=obj.nextInt();
b=obj.nextLine();
System.out.println((a)+" "+(b));;


}
}
question:in this case i can only take int input and program directly terminate. i can cannot take string input .Why and give a solution also??

hiteshpatil
Автор

Sir mera program compile to ho raha but run kyo nhi ho raha enter the valu e ka msg aa raha ar no dene pr a=nhi aa raha

rajatkumarchauorasia
Автор

Intellij pr nhi CHL rhe ye code, m khane vale the intellij download kr lo run krne pr itni dikat nhi ayegi 😂😂😂

riturajsharma
Автор

On running this code on cmd, shows error:file not found: userInput.java
usage: javac <options> <source files>
use --help for a list of possible options.

Please help

AryanKhuman
Автор

User sai input leke program banne and without input liye program bnane mein difference mujhe smjh ni aaya 😢🥺🥺🥺🥺🥺

amritakushwaha
Автор

write a java method to find square and cube number will be taken from user

alokhr
Автор

In Line 9, if we write just obj.nextInt(); and the same in Line 10, we have to do input twice. Why is that, can you please explain?

sabinchand
Автор

Please make a full series of HTML like your C series . Please ❤❤❤

sayanmondal