JavaScript JavaScript Basics Storing and Tracking Information with Variables Using String Methods

Use the JavaScript .toUpperCase( ) string method to assign an all uppercase version of the id variable to the userName v

/

app.js
var id = "23188xtr";
var lastName = "Smith";

 var userName= "string"
index.html
<!DOCTYPE HTML>
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <title>JavaScript Basics</title>
</head>
<body>
<script src="app.js"></script>
</body>
</html>

2 Answers

bible verse
PRO
bible verse
Pro Student 744 Points

First, you want to create the variable, and give it the name "userName".

(Shown here) var userName =

Then use the .toUpperCase method on the variable id.

(Shown here) id.toUpperCase()

Now you put them together,

(Shown here)

var userName = id.toUpperCase()

I hope this helps.