String Basics - Beau teaches JavaScript

preview_player
Показать описание
Strings are a group of characters. Learn all about them in this video!

⭐JavaScript Playlists⭐

-
We're busy people who learn to code, then practice by building projects for nonprofits. Learn Full-stack JavaScript, build a portfolio, and get great references with our open source community.

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

I really like your videos Beau! I think there's an error in this one though. When you show the output you type 'He said Hi!' but I believe you mean to type 'He said "Hi!"' demonstrating the quote around hi?? Thanks for making these!

Holly-iepq
Автор

I think there is a mistake in the video.

Code:
var sentence = "He said \"Hi!\""

Output (Shown):
He said Hi!

Output (Real):
He said "Hi!"

tirdnow
Автор

GRAND SUMMARY

- use \ to escape.. " he said \" Hi \" ", no need to escape different quote, eg " He said 'hi' "
- remember to use same type of quote in the string's start and end.
- list of useful escapable character at 1:31
- concatenation does NOT add spaces b/w words, add yourself !
- string in JS are immutable. you can reuse OLD variables, previously occupied by other strings, to be assigned to NEW strings BUT you cannot modify the string !

- concatenation is possible b/w strings and variables, and can be done line myString+= " new words" .

smyasir
Автор

in which app or website are u demonstrating this java script on?

gamecrafter
Автор

The code where you wrote var sentence = "He said \"Hi!\"";, how about I simply write var sentence = "He said Hi!"; . Will it be different?

eshakotharijain
Автор

Why can't you change the original string?

thedanieljohnson
Автор

I am using my code to make AI so I can rule world

aldeen
Автор

dude the video is wrong..5 minute video and you mess it up.. not to mention not following basic rule to check what u r doing on console. Represent!/...

natenute