// It's good practice to close your scanner when you are done using it. scanner.close(); // I forgot to. So I didn't import java.util.Scanner; public class Main { public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.println("What is your name? "); String name = scanner.nextLine();
System.out.println("How old are you? "); int age = scanner.nextInt(); scanner.nextLine();
System.out.println("What is your favorite food?"); String food = scanner.nextLine();
System.out.println("Hello "+name); System.out.println("You are "+age+" years old"); System.out.println("You like "+food); scanner.close(); } }
for strings , when using scanner , its better to use .next(); instead of .nextLine(); to avoid that error , that worked for me at least . and i have to say , great video , thanks for the efforts . this is by far the most beginner friendly , right to the point , including tricks and errors tutorial. i sincerely thank you bro hahahaha
I just discovered your channel, your way of explaining things without too much fuss and in an easy way is amazing, greetings from Honduras and thanks a lot👻.
This is the best Java tutorial for beginners, so you can learn Java and English in one hit. Please keep going! I vote for Java advance tutorial. Thanks a lot Bro
This tutorial is fantastic! The explanations are clear and concise, making it easy to follow along. I've been struggling with understanding [specific programming concept], but your examples really helped clarify things. Thank you for breaking down complex topics into manageable steps. Looking forward to more videos like this!
I like how you tackled the newline character stuck in the buffer integrated concept (I would still call it an error). I was taught that the buffer needed to be cleared, and I still do not know how to visualize a buffer.
eyyy new bro here, I had been dealing with a lot of difficulties on understanding Java and thanks to you it gave me a on point lesson to different difficulties. Keep it up bro I know that you can help more beginner like me.
Bro really you made it so easy for me Thanks a lot for that bro Whenever I get stuck I come to your channel and as always I return with a great happy feeling and also with understanding the concept ❤❤❤❤❤❤❤❤❤❤❤❤❤❤
this is what i did on my own after watching import java.util.Scanner; public class Main {
public static void main(String[] args) {
Scanner x = new Scanner(System.in);
System.out.println("Whats your name?"); String name = x.nextLine(); System.out.println("Whats your age?"); int agr = x.nextInt(); x.nextLine(); System.out.println("Whats your favourite food"); String food = x.nextLine();
System.out.println("Hello "+ name); System.out.println("You are " + agr + " yrs old"); System.out.println("Your favourite food is "+ food); } } its a little confusing since its not as user friendly as pyton and java but your videos help quite a bit.
Excuse me, Mr. Bro. Great tutorials you have here, but could you please make more videos about using pygame? I think it would be fun for people who have mastered Python or at least have an intermediate knowledge of the language. Thank you.
import java.util.Scanner; public class Main{ public static void main{ System.out.println("What is your name"); Scanner x=new Scanner(System.in); String name=x.nextLine(); System.out.println("Your name is: "+name); } }
Sometimes it does not work or maybe i just missing something in my code after i implement the nextLine() method to eat some extra white space; but yeah its very helpful, Thanks bro
You are the best teacher ever
Agree
Agree
Agree
Agree
Agree
This channel is the best thing to happen to my GPA since Chegg
This is incredible bro, can't believe that not a lot of people watch this. That is the way to teach people! Keep it up! Love your videos
Yeah!!!!!!!!!!!!!!!!!!!!!!!
Bro you have no idea how long it took me to wonder why I couldn't enter any input with the nextLine after nextInt. You are awesome!!
That broke down the WHY of scanners for me, rather than "because that's just the way it is." Thank you!
// It's good practice to close your scanner when you are done using it. scanner.close();
// I forgot to. So I didn't
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.println("What is your name? ");
String name = scanner.nextLine();
System.out.println("How old are you? ");
int age = scanner.nextInt();
scanner.nextLine();
System.out.println("What is your favorite food?");
String food = scanner.nextLine();
System.out.println("Hello "+name);
System.out.println("You are "+age+" years old");
System.out.println("You like "+food);
scanner.close();
}
}
thanks for giving it in the comments! also mine kept on saying error on the first line.
Umm....I'm having a problem here please
It says error..system cannot be resolved to a variable
May God bless you, its has been hard since I started college. Now I can Understand better!!!
for strings , when using scanner , its better to use .next(); instead of .nextLine(); to avoid that error , that worked for me at least .
and i have to say , great video , thanks for the efforts .
this is by far the most beginner friendly , right to the point , including tricks and errors tutorial.
i sincerely thank you bro hahahaha
Thank you!!! I took a note of this :)
Next() keyword won't be able to print the whole text, for like name and tittle at the same time
Thanks , it helped a lot
helped me
thanks
If you use ".next();" instead of ".nextLine();", It will be not possible to type more than one word
Example:
Joker - works fine
Joker pro - error
Hey Bro! I am from India and only your tutorials helped me learn programming even my main language didn't help, Thanks a lot, I am a kid btw
I just discovered your channel, your way of explaining things without too much fuss and in an easy way is amazing, greetings from Honduras and thanks a lot👻.
This is the best Java tutorial for beginners, so you can learn Java and English in one hit. Please keep going! I vote for Java advance tutorial. Thanks a lot Bro
if this guy isn't the best teacher in the world idk who is
LOVE YOU BRO
Just started this course...super excited to finish it ❤😊
Using this series alongside with my uni course , love u bro 👊
Bro you use 1% of your knowledge and 99% of your talent to lecture. In one or other way you are the bestest one
This tutorial is fantastic! The explanations are clear and concise, making it easy to follow along. I've been struggling with understanding [specific programming concept], but your examples really helped clarify things. Thank you for breaking down complex topics into manageable steps. Looking forward to more videos like this!
I like how you tackled the newline character stuck in the buffer integrated concept (I would still call it an error). I was taught that the buffer needed to be cleared, and I still do not know how to visualize a buffer.
eyyy new bro here, I had been dealing with a lot of difficulties on understanding Java and thanks to you it gave me a on point lesson to different difficulties. Keep it up bro I know that you can help more beginner like me.
For the first time my code executes without error!! # Thank you so much sir, I love your pattern of writing codes so simple ...
I hope you will get more than 1M views each time you uploaded a new video after one day, in the future.
You are the best programming channel!
Your explanations and examples is very clean and easy to learn. Thank you so much for your effort
Great explanation of the mysterious behavior of the Scanner class.
The shia Labeouf "Just do it" icon made me subscribe. Thanks bro
You made it so simple & super easy to understand. Thank you
Great tutorial. I like seeing how much java differs from python, which is the tutorial language I learned in school.
Dude your tutorials are the best
Finally, get this tutorial that explained this error clearly
Αυτό είναι ένα σχόλιο για το συγκεκριμένο βίντεο. Τι αλγόριθμος και πράσινα άλογα... Αφού ήρθαν οι Έλληνες μη φοβάσαι Bro, η επιτυχία είναι δεδομένη.
Bro really you made it so easy for me
Thanks a lot for that bro
Whenever I get stuck I come to your channel and as always I return with a great happy feeling and also with understanding the concept
❤❤❤❤❤❤❤❤❤❤❤❤❤❤
Man! You saved my java project! Thank you!
this is a comprehensive explanation
Thanks, Bro!! /n explanation was what I was looking for throughout the youtube
best java course!
Thank you so much for this playlist! I'm currently reviewing for our Algorithms class, bro and I totally forgot about it all 😭😭😭
you are a true gigaChad programmer bro!!!
Bro is the realest of all bros
You are a life saver THANK YOU
your videos ara just incredible
Love your style bro!
Thank you for giving us such a great learning material !:)
Excellent Bro ♥️ , You've earned a couple of subscribers!
Short ☑️
Useful ☑️
Practical ☑️
Life Changing ☑️
this is what i did on my own after watching
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner x = new Scanner(System.in);
System.out.println("Whats your name?");
String name = x.nextLine();
System.out.println("Whats your age?");
int agr = x.nextInt();
x.nextLine();
System.out.println("Whats your favourite food");
String food = x.nextLine();
System.out.println("Hello "+ name);
System.out.println("You are " + agr + " yrs old");
System.out.println("Your favourite food is "+ food);
}
}
its a little confusing since its not as user friendly as pyton and java but your videos help quite a bit.
I'm from Jordan, thank's u Bro code u'r professional
Jesus, you are the best man! I discover your channel today!
This is epiccccccccccccccccccccccc loving this.............
Bro is always here for me.
Thank you Bro ❤️❤️❤️
a perfect reviewr ty my dude
Nice and smoothly explained
Very important video of Java for input data by user with keyboard.
wow brother wow very good realy
Very awesome video!
Thank you for the great video! Keep up the good work!
You are simply great, Bro!
You are the best bro !!
Great tutorial bro
Look at the thumbnail though!!😂😂😂😂
Excuse me, Mr. Bro. Great tutorials you have here, but could you please make more videos about using pygame? I think it would be fun for people who have mastered Python or at least have an intermediate knowledge of the language. Thank you.
Super as usually!!
Great tutirial ever !!!!!
good explanation bro
Da best bro in Da entire world
your videos are so useful, thank you
It was helpful thanks❤
You are amazing bro. Thank you so much
Great tutorial! Thanks!
that was helpful thank you :)
I just love your voice, @Bro Code !!
found it very helpful
Thanks Bro for a great lesson!
thank for teaching. I learnt from you
thanks for this tutorial bro
I miss C so much 😭
Very easy to understand. Thank you :)
Great video , thanks for the efforts !!!
good lesson, bro
incredible video, thank you bro
this easy learn thanks of course !!!
import java.util.Scanner;
public class Main{
public static void main{
System.out.println("What is your name");
Scanner x=new Scanner(System.in);
String name=x.nextLine();
System.out.println("Your name is: "+name);
}
}
Another lesson that i understood
Thanks Giga Bro🔥
great video bro!!
you are amazing!
Nice Work
Thanks. good class
Great Video, Bro!
Thanks for the help on java, I was using a school computer so I couldn't like or comment. I'm doing that now.
Scanner scanner = new Scanner(System.in); -> you could have explained why System.in is passed here. Anyway your tutorials are awesome
Thx for video bro !
Sometimes it does not work or maybe i just missing something in my code after i implement the nextLine() method to eat some extra white space; but yeah its very helpful, Thanks bro
Hey Bro,I have a question from my school I have an image where can I send the image?Please clarify my doubt of menu based programs🙏
bro, i watched ur java tutorial (10, 4 hours) and all i learnt its "its ur bro...ladies and gentlemans" ha ha , jk i liked ur video... and Corvette
Thanks❤ for it bro
Fellow bro ❤️
Thank you very much
a lot of prayers to the algorithm!
you deserved M views for every video
Thanks bro😊
Thank You ❣