Notebooks 2.0 is here.

Published
Edited
Jan 22, 2021
2 forks
Insert cell
md`# Kada Coding, Class 3 Functions

* Functions
* Arrays
* Code blocks`
Insert cell
html`

<div>
Esto es <strong>HTML</strong>
</div>
<!-- Write your comments here -->
<p>
Uno <br/>
Dos <br/>
Tres <br/>
</p>

<p>Esto es un párrafo</p>
<p>Esto es un párrafo, <span id="bigger">John</span></p>
`
Insert cell
gradesMd = md`# Student Grades


${img}

<img src="pic_trulli.jpg" alt="Italian Trulli">


<input type="text" placeholder="Enter your name">

Student | Grade
-- | --
Mafe | 4.9
John | 0.3
Cata | 4.8
Pipe | 0.3


<table>
<th>
<td>Student</td>
<td>Grade</td>
<th>
<tbody>
<tr>
<td>Juan</td>
<td>23</td>
</tr>
</tbody>
</table>
...

`
Insert cell
img = FileAttachment("Screen Shot 2021-01-21 at 5.47.21 PM.png").image()
Insert cell
name = "John Alexis"
Insert cell
name.length
Insert cell
name.toUpperCase()
Insert cell
elTony = FileAttachment("foto_JohnGuerra_May_2019_med.jpg").image()
Insert cell
elTonyUrl = FileAttachment("foto_JohnGuerra_May_2019_med.jpg").url()
Insert cell
md`
## El Tony

${elTony}

<img src="${elTonyUrl}">
`
Insert cell
a = 32
Insert cell
b = 21
Insert cell
a + b
Insert cell
function saludar() {
return "HOla!!!";
}
Insert cell
saludar()
Insert cell
saludar()
Insert cell
saludar()
Insert cell
md`


El resultado es ${saludar(1234)}


`
Insert cell
function saludarA(aQuien) {
return "HOla " + aQuien;
}
Insert cell
saludarA()
Insert cell
saludarA("Mafe")
Insert cell
saludarA("Laura")
Insert cell
md`


Student | Name Length | Capitalized Name
-- | -- | --
Laura | 5 | LAURA
Mafe | 4 | MIFE
Cata | 4 | CATA



`
Insert cell
name1 = "Mafe"
Insert cell
name1.length
Insert cell
name1.toLocaleUpperCase()
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more