Capitalize The First Letter of a String in Java #30

  Рет қаралды 39,949

Alex Lee

Alex Lee

Күн бұрын

$1,000 OFF ANY Springboard Tech Bootcamps with my code ALEXLEE. See if you qualify for the JOB GUARANTEE! 👉 bit.ly/3HX970h
We can capitalize the first letter of a string by using string methods. In this java tutorial, I show you how to use the substring and toUpperCase methods to create a new string with the first letter capitalized.
I hope this helps you make your java program :) This is GREAT practice for getting your feet wet in java!
I hope you enjoyed java program tutorial!
Full Java Tutorial For Beginners Playlist: • Full Java Course by Al...
Free Tips: bit.ly/3U6HXcb
Disclosure: Springboard link provided is linked to my affiliate account & supports the channel.
Alex Lee

Пікірлер: 101
@alexlorenlee
@alexlorenlee 11 ай бұрын
If you’re new to programming but want a career in tech, I HIGHLY RECOMMEND applying to one of Springboard’s online coding bootcamps (use code ALEXLEE for $1,000 off): bit.ly/3HX970h
@PankajRai
@PankajRai 4 жыл бұрын
Yes indeed today is my birthday 🎉
@alexlorenlee
@alexlorenlee 4 жыл бұрын
WOOH Happy Birthday! :)
@PankajRai
@PankajRai 4 жыл бұрын
@@alexlorenlee thanks ♥️
@petarpetrovich2649
@petarpetrovich2649 4 жыл бұрын
String a = "Nice vid Alex"; sysout(a);
@og_gaming2323
@og_gaming2323 4 жыл бұрын
ctrl spc
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
:1: error: class, interface, or enum expected string a = " Nice vid Alex"; ^ :2: error: class, interface, or enum expected sysout(a); ^ 2 errors
@sowjanyasharma6481
@sowjanyasharma6481 4 жыл бұрын
Great work Alex
@HussamAdil
@HussamAdil 4 жыл бұрын
public static void main(String[] args) { //thanks Alex and this another solution using stringbuilder // happy coding StringBuilder name = new StringBuilder( "hussam"); String firstLetter = name.substring(0,1).toUpperCase(); System.out.println(firstLetter); name.deleteCharAt(0); name.insert(0,firstLetter); System.out.println(name); }
@anuragpanda4216
@anuragpanda4216 4 жыл бұрын
What does StringBuilder do?
@v1araujor1
@v1araujor1 4 жыл бұрын
Alex, I am looking forward to seeing videos of yours explaining more intermediate stuff in Java. Things like... layout managers? Maybe a series of videos on that matter. Stuff like modelling a project, with MVC, maybe? Hope you read this comment. Love your work!
@techamatuer8115
@techamatuer8115 5 ай бұрын
your explanation is much better
@daives01
@daives01 4 жыл бұрын
Thank you so much for your videos! They are awesome and I would be really struggling without them
@sowjanyasharma6481
@sowjanyasharma6481 4 жыл бұрын
Yeaa
@alexlorenlee
@alexlorenlee 4 жыл бұрын
You're welcome!
@joethompson8147
@joethompson8147 4 жыл бұрын
Great job here Alex! I have a gut feeling that String methods will be on the 2020 AP CS"A" somewhere so I looked for good videos and found this!
@lumdermaku
@lumdermaku 4 жыл бұрын
☕☕☕☕ Please start using intelliJ with dark mode instead of the ancient eclipse
@baohoangle3901
@baohoangle3901 4 жыл бұрын
I think eclipse is beter.
@duckking7642
@duckking7642 4 жыл бұрын
Eclipse looks good on mac, and it fits well for his tutorials in my opinion, but if you want to do java then yes I suggest IntellIJ IDEA but other than that, eclipse is good for other programming languages
@dhananjayand3057
@dhananjayand3057 4 жыл бұрын
Please do the Algorithms and Data Structure Playlist
@ideology8323
@ideology8323 4 жыл бұрын
perfect timing! 👌
@sareer
@sareer 17 күн бұрын
Mean while in python s.capitalize()
@dory9514
@dory9514 3 жыл бұрын
Thank you so much!!!!!!!!!!
@vivekanand5900
@vivekanand5900 4 жыл бұрын
Great explanation 😇😇
@harpreetkaursodhi3298
@harpreetkaursodhi3298 4 жыл бұрын
Hey Alex, thank you for your every video as they helped me alot in learning Java! I want u to share some stuff about Java Applets. Thanks alot !
@atharvsoni5308
@atharvsoni5308 2 жыл бұрын
I dont think anyone would be watching your video on their birthday
@ДмитрийАницой
@ДмитрийАницой 3 жыл бұрын
How do you know it's my birthday today? Thx!
@durairuna6068
@durairuna6068 Жыл бұрын
Man you saved me from my task performance. I've been having a hard time lately so I couldn't focus at school. All your tutorials are very useful. Thank you.
@mr.sakowicz2888
@mr.sakowicz2888 3 жыл бұрын
Amazing! I just watched ten or more videos trying to figure out how to do just this and finally, it all comes back - once again - to the great ALEX LEE! Cheers, bud! :)
@dhananjayand3057
@dhananjayand3057 4 жыл бұрын
Please post a video about Bit Manipulation in java
@jacobyealy9962
@jacobyealy9962 4 жыл бұрын
What are the chances im just now seeing this but it was posted on my birthday!
@abdulbrown1954
@abdulbrown1954 3 жыл бұрын
Unfortunately I can’t use substrings for my itec class
@vinukumarvinu6220
@vinukumarvinu6220 4 жыл бұрын
Good vedio and it very and very helpful
@AmitYadav-nz5if
@AmitYadav-nz5if Жыл бұрын
Hey Alex! What to do if I want every first letter of the word in Capital? Lets's say there is "hello alex good morning" and i want "Hello Alex Good Morning" . What will be the program?
@bbcguy8327
@bbcguy8327 2 жыл бұрын
Just do -32 and cast to char
@rishavraj1394
@rishavraj1394 4 жыл бұрын
Java Ninja...bro can u make atleast 2 3 videos per week..bcz ur explanation is superb
@cesarraynor2121
@cesarraynor2121 4 жыл бұрын
Using scanner. I am moving the first word of a string to the end and the second word in the string is now the new first word. I completed the program BUT! I do not know how to only capitalize the first letter of the new word. Please help!
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
Just do as he did in the video with new the string and print out the new string
@jamalj6718
@jamalj6718 4 жыл бұрын
Mate you're a legend.....I need help I've got an assignment where I need to display my program on the internet, it's a payroll system and another program...... How or what's the code used in order to display it on the internet
@bashardd9254
@bashardd9254 2 жыл бұрын
amazing
@TerribleNews1
@TerribleNews1 Жыл бұрын
How can I ignore the first index of a word?
@prernakamble9650
@prernakamble9650 2 жыл бұрын
I like the way you teach. Helps me learn quickly.❤️
@hodactruong
@hodactruong 2 жыл бұрын
Hi @alex lee. How could I keep the same with a word that only has 1 letter? Mean that my input is :"this is a book" then return: "This Is a Book" Thanks you
@brahmanandakabi8796
@brahmanandakabi8796 2 жыл бұрын
Thank you, bro.Hope god bless you long life. blessings from my inner heart
@nightshocker03
@nightshocker03 3 жыл бұрын
geez.. imagine doing more work just to add a capital letter
@courses5720
@courses5720 Жыл бұрын
It is my birthday. Now I am master of lowercaases.
@balabhadrasairam9641
@balabhadrasairam9641 Жыл бұрын
For birthday we need capital B means
@BrettBourne
@BrettBourne 3 жыл бұрын
I need grab the last three characters and put them to lowercase and I do not know what I should be doing here. How would I go about using the substrings or code to make the last three characters of whatever my user inputs for a string, lowercase?
@narinarendra7087
@narinarendra7087 14 күн бұрын
Thank you so much
@dangergranger5091
@dangergranger5091 3 жыл бұрын
Bro you look so done with life in this vid lol
@chazk.official873
@chazk.official873 4 жыл бұрын
Great video as always. Would be great if you could do a deeper lesson on file handling. You're the best teacher in java!
@sachiionlineacademy
@sachiionlineacademy 4 жыл бұрын
kzbin.info/www/bejne/rnSXlnttgb-Xqac link for java file handling exercise it may help you
@phomolomanuel1743
@phomolomanuel1743 2 жыл бұрын
you are the best God bless you😁😇
@SinaSweden
@SinaSweden 2 жыл бұрын
Your vidoes help me a lot.
@study-st3th
@study-st3th 6 ай бұрын
icse 10 students 👇
@eien7228
@eien7228 4 жыл бұрын
why many people hate java?
@takookiechimchim7466
@takookiechimchim7466 4 жыл бұрын
how do i make the whole string into capital letters
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
. toUpperCase() ;
@beryosa
@beryosa Жыл бұрын
Thank you. Finally I fount exactly what I was looking for.
@Dabi711
@Dabi711 2 жыл бұрын
thank you so much
@sho2648
@sho2648 7 ай бұрын
thanks a lot
@mr.sakowicz2888
@mr.sakowicz2888 3 жыл бұрын
this is great- however now wondering how we could do this with user input- that would be an un-pre-defined string length- so I wonder if we could get the length and use that to run this string method? yikes my head hurts- help? ;)
@whitedevilofficialgaming7222
@whitedevilofficialgaming7222 3 жыл бұрын
Thank you Sir
@maryamjubeh1797
@maryamjubeh1797 4 жыл бұрын
Thank youuuu ☕☕☕☕
@hi-vk2sm
@hi-vk2sm 4 жыл бұрын
Pls do more video about string methods, this is soo fun!!
@sachiionlineacademy
@sachiionlineacademy 4 жыл бұрын
This is the link for the string and its important methods: kzbin.info/www/bejne/fWHYk4Vooqx5gKc
@thedidiandfufushow2693
@thedidiandfufushow2693 3 жыл бұрын
i love you
@shirshakupadhayay1315
@shirshakupadhayay1315 4 жыл бұрын
multithreading
@introvertsdiary
@introvertsdiary 3 жыл бұрын
I want the first letter of the second word capitalize .. how to do it?
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
Do the same as he did in the video but reverse like add the First word then capitalize the first letter then add the rest of the word
@tiboomvds344
@tiboomvds344 4 жыл бұрын
Can you make a video for picture input or make a serie where you make a desktop program
@bokica4089
@bokica4089 4 жыл бұрын
Alex please make a video about serialization and deserialization
@NAhiagbedey
@NAhiagbedey 4 жыл бұрын
is the audible link working for anyone?
@Sport-word
@Sport-word 4 жыл бұрын
Xup Alex ..how do you grow your KZbin channel ? Do you use any tool?
@EL.THIKA_Programmation
@EL.THIKA_Programmation 4 жыл бұрын
slm, how i can protect my application java against theft and decompiler java
@jeyhunaliyev1765
@jeyhunaliyev1765 4 жыл бұрын
👍
@pranaykhimji9811
@pranaykhimji9811 4 жыл бұрын
Hey Alex! Hope you're doing well! Can you please make a java chess game?
@janinaalmog7312
@janinaalmog7312 2 жыл бұрын
Thanks Alex, your videos really make sense to me👌
@jonghyunchoi1284
@jonghyunchoi1284 4 жыл бұрын
You are the best KZbinr! I always appreciate your video and again thank you for help to understand me.
@zarllastimadarazon6738
@zarllastimadarazon6738 3 жыл бұрын
You help me a lot, you're a lot better than my prof'
@rstuk6613
@rstuk6613 4 жыл бұрын
but how do you capitalize both words???? I'm lost in trying to figure this out!
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
Do the same he did with the first word but just with the second word
@liambrain7551
@liambrain7551 4 жыл бұрын
Please do a StdDraw tutorial
@janaldrinmanahan7330
@janaldrinmanahan7330 4 жыл бұрын
I am confused about the s.substring(0,1) and s.substring(1)
@Nobodyokbro
@Nobodyokbro 3 жыл бұрын
substring(0,1) Says go from index 0 - index 1 ex. hello it prints h the second one say go from Index 1 to the end of the string ex. Hello it prints ello
@renecabuhan1675
@renecabuhan1675 4 жыл бұрын
Good morning sensei.
@svensoelberg6730
@svensoelberg6730 4 жыл бұрын
thankyou lad
@patrickcodog8834
@patrickcodog8834 4 жыл бұрын
Thanks sir! I need this to my system
@MuhammadAli-ci7qp
@MuhammadAli-ci7qp 4 жыл бұрын
u de best bro
@MrNotSelc
@MrNotSelc 4 жыл бұрын
DROP YOUR SKINCARE ROUTINE
@kevinbeharrilal1609
@kevinbeharrilal1609 4 жыл бұрын
aloe vera
@introvertsdiary
@introvertsdiary 3 жыл бұрын
I love you
@kevinbeharrilal1609
@kevinbeharrilal1609 4 жыл бұрын
Bro my eclipse IDE doesnt work antmore, something about error 2
@dannielpotter2259
@dannielpotter2259 4 жыл бұрын
is it due to update of java....
@self-coder1621
@self-coder1621 4 жыл бұрын
copy the code and make a new project and class and paste it in the class
@manikandan-qh3oi
@manikandan-qh3oi 2 жыл бұрын
Type Sout.. And Press tab button... system.out.println();... 😅☕☕
@sowjanyasharma6481
@sowjanyasharma6481 4 жыл бұрын
BTW, PLS GIVE ME A SHOUT OUT PLS
@deepdaddy1208
@deepdaddy1208 4 жыл бұрын
SHOUT OUT
@rishavraj1394
@rishavraj1394 4 жыл бұрын
🤣
@ferfykins
@ferfykins 4 жыл бұрын
Love your channel, thanks for the video!! Hope to see more exercises or even projects!!
Java Multiple Choice Quiz Program Tutorial #31
13:06
Alex Lee
Рет қаралды 22 М.
Abstract Class In Java Tutorial #79
8:55
Alex Lee
Рет қаралды 542 М.
SHAPALAQ 6 серия / 3 часть #aminkavitaminka #aminak #aminokka #расулшоу
00:59
Аминка Витаминка
Рет қаралды 2,2 МЛН
🍉😋 #shorts
00:24
Денис Кукояка
Рет қаралды 3,6 МЛН
Capitalize first letter of each word using java
13:04
Automation Hub Software Testing
Рет қаралды 20 М.
Inheritance in Java Tutorial #86
10:34
Alex Lee
Рет қаралды 385 М.
Return Statement in Java #27
14:38
Alex Lee
Рет қаралды 277 М.
Typing Speed Java Program - Calculate WPM #60
13:27
Alex Lee
Рет қаралды 34 М.
Static in Java Tutorial #75
6:16
Alex Lee
Рет қаралды 258 М.
Object-Oriented Programming Java Tutorial (Java OOP) #71
14:07
For Each Loop In Java Tutorial #39
9:08
Alex Lee
Рет қаралды 135 М.
For Loop Pattern Program In Java #25
15:49
Alex Lee
Рет қаралды 168 М.