public static void main(String args) In Java - What is String args?

preview_player
Показать описание

In this video, I show you what String[] args means in the main method:

public static void main(String[] args) {}

String[] args is just a variable you can use in the Main method! It's an array of Strings that gets passed through the main method when it gets run. There are a few ways to do that, which I show you in this video :)

I hope you enjoyed this tutorial on what "args" is in public static void main(String args) in Java!!

Disclosure: The Springboard link provided is linked to my affiliate account & supports the channel.

~

Alex Lee
Рекомендации по теме
Комментарии
Автор

i have been wondering about the use of the args array and now i know!! thanks

yaprak_sarma
Автор

I just started learning Java like 2 weeks ago, it’s awesome that you have so many tutorials I’ve been just absorbing the knowledge. It’s much appreciated 🙏

light_skit
Автор

I am so glad you're back! Thank you from all of us unprivilaged by life! Greetings from Poland ❤

Ginger
Автор

Java tutorials king is back.🎉👍👍👍
Love from India 🇮🇳 ❤😁

Shelby_itachi
Автор

Been wondering about this since I started Java a few years ago, thank you! The CLI demonstration really helped me understand a few CLI apps I have on my system, very nice!

Winter_
Автор

Thank you for all of your help. Had to learn java in less than a week for a job interview (already sort of familiar with programming). And you have prepared me more than I could ever repay you. Teaching is a talent of yours and can't express my gratitude enough. Even if I don't get the job I've gained so much knowledge in such a short amount of time, forever grateful. Thank you and you will succeed in anything you choose to pursue!

decaTRT
Автор

You are helping me so much this semester. You changed my hate and disdain for java into something I'm truly curious about and growing to like more each day. Its 5 am I cant sleep and i am watching your video 😂😂😂 not because a pressing assignment is due but just to learn. I wish there was a way to individually book with you for hands on help on different projects or a way to suggest topics. I hope you continue to make content and find new and engaging ways to bring the material across. Thank you!

GraciaBella-mf
Автор

I used to watch your videos a few years ago they helped me with understanding a lot of my subjects in java. Now I graduated and just wanted to thank you for providing and spreading these beneficial videos to everyone ^_^...Thank you Alex!!

quuedgq
Автор

So excited to see a new Java tutorial from you!! This made my day! This is literally my favorite YouTube channel and hobby! 😂❤

memeingthroughenglish
Автор

I've learned so much from your videos. You make Java approachable for the average Joe. Thanks man!

desertedislander
Автор

Alex?! Is that really you? 😊 Welcomeback!

marko
Автор

Thanks for helping me understand what String[] args is! I was just thinking what would happen if I printed the args array…. thank you!

jamesvowles
Автор

Since I started learning Java, I watched your videos. I'm in my junior HS but yeah I love coding. And I'm just wondering if you can make a vd about how to memorize Java projects or making own projects without looking back again. I would be really appreciate if you made it.

waimoe
Автор

Thank you Alex, best videos out there

richirod
Автор

Hi Alex, can u do a series on S.O.L.I.D principles

SGTN
Автор

So cool man, i just going to my pc to try it now!!

NatyTor
Автор

Are you back on giving Java lessons? Tell me yes pls!!! 😊

nesuleo
Автор

nothing against Eclipse but have you ever considered using IntelliJ IDEA or at least trying it out?
im not a long time viewer of your channel so i don't know if you've done anything like that on here but just thought i should put it out there because Eclipse seems a bit like a thing of the past and IntelliJ is a lot newer feeling and user friendly.

lordender_kitty_official
Автор

I just got admission into Computer Science Department and I want to start practicing Java programming at home. pls what is the name of the software you are using for the java programming so I can install it on my computer for practice?

olasuccess
Автор

I see why the executable (or class file argument) itself isn't taken unlike in C/C++. Because the file has the same name as the main class :)

k_gold