Characters

5 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$99.99
List Price:  $139.99
You save:  $40
€85.34
List Price:  €119.48
You save:  €34.13
£74.02
List Price:  £103.63
You save:  £29.61
CA$138.36
List Price:  CA$193.71
You save:  CA$55.35
A$152.51
List Price:  A$213.52
You save:  A$61.01
S$128.50
List Price:  S$179.91
You save:  S$51.40
HK$779.53
List Price:  HK$1,091.37
You save:  HK$311.84
CHF 79.80
List Price:  CHF 111.72
You save:  CHF 31.92
NOK kr1,004.57
List Price:  NOK kr1,406.44
You save:  NOK kr401.87
DKK kr637.04
List Price:  DKK kr891.89
You save:  DKK kr254.84
NZ$169.67
List Price:  NZ$237.55
You save:  NZ$67.87
د.إ367.21
List Price:  د.إ514.11
You save:  د.إ146.90
৳12,136.98
List Price:  ৳16,992.26
You save:  ৳4,855.27
₹8,817.76
List Price:  ₹12,345.22
You save:  ₹3,527.46
RM422.40
List Price:  RM591.38
You save:  RM168.98
₦152,170.38
List Price:  ₦213,044.63
You save:  ₦60,874.24
₨28,298.93
List Price:  ₨39,619.64
You save:  ₨11,320.70
฿3,204.79
List Price:  ฿4,486.84
You save:  ฿1,282.04
₺4,119.83
List Price:  ₺5,767.93
You save:  ₺1,648.10
B$541.35
List Price:  B$757.91
You save:  B$216.56
R1,758.69
List Price:  R2,462.23
You save:  R703.54
Лв167.02
List Price:  Лв233.83
You save:  Лв66.81
₩138,636.13
List Price:  ₩194,096.13
You save:  ₩55,460
₪332.89
List Price:  ₪466.07
You save:  ₪133.17
₱5,669.43
List Price:  ₱7,937.43
You save:  ₱2,268
¥14,738.72
List Price:  ¥20,634.80
You save:  ¥5,896.07
MX$1,871.33
List Price:  MX$2,619.94
You save:  MX$748.60
QR364.50
List Price:  QR510.31
You save:  QR145.81
P1,340.79
List Price:  P1,877.16
You save:  P536.37
KSh12,904.65
List Price:  KSh18,067.03
You save:  KSh5,162.37
E£4,853.17
List Price:  E£6,794.63
You save:  E£1,941.46
ብር14,265.58
List Price:  ብር19,972.39
You save:  ብር5,706.80
Kz91,690.83
List Price:  Kz128,370.83
You save:  Kz36,680
CLP$96,951.70
List Price:  CLP$135,736.26
You save:  CLP$38,784.55
CN¥713.21
List Price:  CN¥998.52
You save:  CN¥285.31
RD$6,306.89
List Price:  RD$8,829.90
You save:  RD$2,523.01
DA12,985
List Price:  DA18,179.52
You save:  DA5,194.52
FJ$225.25
List Price:  FJ$315.36
You save:  FJ$90.11
Q764.86
List Price:  Q1,070.83
You save:  Q305.97
GY$20,864.62
List Price:  GY$29,211.30
You save:  GY$8,346.68
ISK kr12,214.60
List Price:  ISK kr17,100.93
You save:  ISK kr4,886.32
DH906.33
List Price:  DH1,268.90
You save:  DH362.57
L1,673.87
List Price:  L2,343.49
You save:  L669.61
ден5,249.20
List Price:  ден7,349.10
You save:  ден2,099.89
MOP$801.49
List Price:  MOP$1,122.12
You save:  MOP$320.63
N$1,762.97
List Price:  N$2,468.23
You save:  N$705.25
C$3,670.35
List Price:  C$5,138.63
You save:  C$1,468.28
रु14,083.64
List Price:  रु19,717.66
You save:  रु5,634.01
S/351.28
List Price:  S/491.80
You save:  S/140.52
K416.25
List Price:  K582.76
You save:  K166.51
SAR374.98
List Price:  SAR524.99
You save:  SAR150
ZK2,380.99
List Price:  ZK3,333.48
You save:  ZK952.49
L433.17
List Price:  L606.46
You save:  L173.28
Kč2,080.74
List Price:  Kč2,913.12
You save:  Kč832.38
Ft33,490.30
List Price:  Ft46,887.77
You save:  Ft13,397.46
SEK kr939.43
List Price:  SEK kr1,315.24
You save:  SEK kr375.81
ARS$136,364.55
List Price:  ARS$190,915.83
You save:  ARS$54,551.27
Bs689.11
List Price:  Bs964.79
You save:  Bs275.67
COP$397,708.14
List Price:  COP$556,807.31
You save:  COP$159,099.16
₡50,530.25
List Price:  ₡70,744.37
You save:  ₡20,214.12
L2,612.83
List Price:  L3,658.07
You save:  L1,045.23
₲718,801.20
List Price:  ₲1,006,350.44
You save:  ₲287,549.23
$U4,014.67
List Price:  $U5,620.70
You save:  $U1,606.02
zł362.63
List Price:  zł507.71
You save:  zł145.07
Already have an account? Log In

Transcript

Hello, in this Java programming video, we are going to look at characters. So we've taken a look at characters and the char datatype. Before in the datatype video, we're going to advance it a bit further and have a look at escape sequences, have a look at the different you know, Java methods that, you know, is provided to help manipulate characters as well. So let me have a quick look at escape sequences. So for creating character, so, if I were to call it C, and if I assign a value so anybody so that's a sign of value, our backslash t so this is the tab character, even though it's got to counter that, you know people because got that flashing means an escape sequence. So you just know one form character, system, dot out dot print.

Ln. So if let's say I just put Hello, like so it puts Hello. But let's say if I put C at the start of it. I'm gonna, I didn't see he puts a tab though he puts a tab character, you can put that anywhere. So if I were to put it here as well, and I put world and run it there we go, we got the top character inside as well. So the next thing to note, I can you might wonder why the space is a little different to this space.

So the space should be this, you know, in Thailand, but he actually goes from where this is, as you can see that is the exact line to this. So it's not where it starts. It's from the previous tab, and also bear in mind, well, there's a bunch of other escape sequences, like where you can insert a single quote as well, you can insert a backspace in the text if you want to be a link with this video where you can check all of the different features out. Now, let's cover some of the methods that are available to us. So let's create a new coat. I'll call it char.

Awesome. equals and I am going to call this a C. Call this big is easy to see if it's okay so the case and you'll see in a second. So what we can do is we can check a letter simply by doing the system dot print ln missing the end So System dot out dot print line, I'm going to say character.is letter. So if it's a letter awesome in here, and we run it, it puts a tricky so let's say follows. Character eight. Now, it's not a letter, but it is still a valid character.

So that's really cool. If you're checking if letting go some user input, and maybe the number breaks it or the number doesn't break it, you can do it. What's the number one four, if it's a number one let you check that out from the link Darrell provides. So I want to cover a couple more. One is checking if it's uppercase. So let's have a look at the system dot print.

Lm in here. Awesome. And if I change this to be I'm sorry, I'm in character not to cater is okay. And I'll provide character and you could put it in line. However, if you want to do something like that, well, you can use this you know, wherever you want, you could use it in an if statement, they just returns true or false printing so you can immediately see, what we notice is false. If I change this to a capital V, our vessels don't technically ascend that tell you when we looked at it, it is true.

And one final one that I'm going to cover if the lower case Under this system quintella character.to uppercase under the two locations also feel free to check them. Awesome. And if I were to print this out, you just print printed the same way a lowercase b however, it prints out D, uppercase B. So we've covered quite a few methods and escape sequence character as well in this character video. If you have any questions or you want to check out more of the functionality that you can do with characters, feel free to check out the link with you know this tutorial. If you have any questions also feel free to reach out as usual.

Thanks for watching, and look forward to seeing you in the next awesome video.

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.