Hello and welcome to the Golden and Programming Languages course in this section devoted to talking
about string concepts.
This strings in go, Lang.
Ingo Language's histories are different from other languages like Java, C++, Python and etc..
It is a sequence of very evil with characters where each and every character is represented by one or
more by using UTF eight and coding or in other wars.
Extremes are the immutable chain of arbitrary bias, including bias with zero value or string is read
only a slice of bias, and the bias of the strings can be represented in the Unicode takes using UTF
eight encoding due to UTF eight, including go language string can contain it takes, which is the mixture
of any language presenting the work without any confusion and limitation of the page.
Generally, extremes are enclosed in double quotes.
This string literal.
In language is strong, literatures are created in two different ways.
First, using double quotes here, they assume these roles are creating using double quotes.
This type of string support escape character, but does not expand multiple lines.
This type of string e-tron's is widely used in goal and programs.
Second, using tactics here of the extremely strong are created using back ticks and also known as road
ROMs.
Roll it rolls do not stop.
All escape characters can expand multiple lines and may contain any character except Bektic.
It is generally used for writing multiple line message in the regular expression and invest in it.
Let's go to this school program to illustrate how to use strings.
First, go to Explorer and create a project folder
for the example strings and create a file name like me that go go to the file and create package name
and create meaningful punch hole, hopefully creating and initializing a variable with the string using
shorthand declaration for the example
name one column equals and set a value for display.
The link came second, creating and initializing every bit with the string, using bad keyboard and
using double code and adding escape character.
Go to the next line.
Define that name to.
Tie this string equals
go through your end and cityscape character like Beckett's left end and language and turn creating an
initializing a variable with a string, using that keyboard, using back ticks as in the it rolls and
adding escape character.
That name.
Three Typekit, this drink he calls back take.
Go through training and sit this gay character like back in snatch and language now displayed these
extreme variables.
If we name one, if the name to display name three, reformat the code and save the projects, go to
the terminal first, go to Project Folder, see the strings and run the program by the client.
Go on the main dot go.
Now we can see the outputs.
The first variable is printed normally gene, and in the second very that we have used escape character.
This causes a part of the case to be transferred to the next line, go programming in a line and language
in another line.
But in the third that we have used around e-tron's and inside it, you have used this Gear character.
Motorola authorized do not support ASCII characters, and the value of the variable is displayed in
full on one line in order not to prolong the time of decision.
We will finish it and we will continue the content in the next session.
Goodbye.