html
html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<!-- Creating the paragraphs -->
<!-- Creating heading, adding strong -->
<!-- Adding the page structure HTML, BODY, P -->
<!-- Adding a link nested in an image -->
<html>
<!-- Wrapping the body into a section tag -->
<section>
<body>
<h1> The Eiffel Tower </h1>
<!-- <a href="https://test.com" target="_blank"> some link -->
<img src="https://sololearnassets.azureedge.net/eiffel-tower.jp"
alt="Eiffel tower image" width="30%"> </a>
<p> <strong> The Eiffel Tower </strong> is a wrought-iron tower that stands <strong>1,063 ft (324 m)</strong> tall in Paris. </p>
<p>Currently, the <strong> Eiffel Tower </strong> is the most-visited monument in the world with over <strong> 7 million </strong> visitors a year.</p>
<p>Visitors can choose to go up using the Tower lift or the stairs. There are <strong>1,665 steps </strong> to the top.</p>
<!-- Adding a paragrapgh -->
Enter to Rename, Shift+Enter to Preview
css
css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* Grabbing selectors to style the website */
/* Styling the header */
/* Adding space to the head */
/* Adding marging */
h1 {
font-size: 20px;
letter-spacing: 2px;
margin: 10px 0px 10px 0px;
}
/* Styling the labels */
label {
font-size: 16px;
font-weight: bold;
}
/* Only the strong tags */
strong {
color: #2493df;
Enter to Rename, Shift+Enter to Preview
js
js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* Creating variables */
let adults = parseInt(document.getElementById("adults").value);
let children = parseInt(document.getElementById("children").value);
let price = (adults * 12) + (children * 5);
/*console.log(price);*/
/* Reviewing if the input on aduls and children, is a negative
number, if it is, will be changed to 0 */
if (adults < 0) {
adults = 0;
}
if (children < 0) {
children = 0;
}
/* Crating a program to print the tickets, for the adults */
for(let i = 1; i <= adults; i++) {
console.log("Ticket #" + i);
}
Enter to Rename, Shift+Enter to Preview
BROWSER
Console
Run