Published
Edited
Feb 8, 2020
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
{
var bob = {name: "Bob", emotion: "happy", species: "Hooman"}
return bob
}
Insert cell
Insert cell
{
var bob = {
name: 'Mr. Bobz',
caffeinated: true
}
return bob.name
}
Insert cell
Insert cell
function eat() { return "WHERE IS MY NOMS?"}
Insert cell
{
var bob = {name: "Bob", emotion: "Hangry", eat: function() {return "Om nom nom"}}
return eat()
}
Insert cell
{
var bob = {name: "Bob", emotion: "Hangry", eat: function() {return "Om nom nom"}}
return bob.eat()
}
Insert cell
Insert cell
{
var bob = {
name: 'bobz',
hangry: false,
eat: function() {
return hangry;
}
}
return bob.eat()
}
Insert cell
Insert cell
{
var bob = {
name: "Bob",
emotion: "Hangry",
eat: function() {
this.emotion = "Full"
}}
bob.eat()
return bob.emotion
}
Insert cell
Insert cell
thisOutOfContext = function() {
// what could `this` be?
return this;
}
Insert cell
Insert cell
{
var doggo = {
bark: function() {
return this.sound
},
sound: 'wooof!'
}
var doggoII = {
bark: doggo.bark,
sound: 'not wooof!'
}
return doggo.bark()
}
Insert cell
Insert cell
Insert cell
Insert cell
function jerry() {
return
//debug starting here
{
name: 'Jerry'
superpower = 'intelligence'
powerScore: 22
getPower: function() {
return powerScore
}
{
powerUp: function() {
powerScore = score + 20
},
}
setPower: function(score) {
powerScore = score
{
favoriteFood: function() {
if(powerScore > 50) {
return 'chz'
}
else {
return 'mousetrap chz'
}
}
}
//debug ending here
}// I spent from 6:30 to 9(((its 9:30 now and I forgot how I did the cat code and now the dog code is extra fun && (will = disappoingmenttttt)) = true)
//on this and I googled and I plugged everything in and I wrote this out on paper and not only did I not get anywhere but I didnt get anywhere and I clicked imports on the bottem by accident and now I have to reset all three questions so I'm not doing this question I'll talk to one of you about it but I can't stand that I try everything in my power and spend a good portion of my friday night coding and I am not getting anywhere I feel like a child and I'm helpless
Insert cell
Insert cell
Insert cell
Insert cell
superCat = function() {
var superCat =
{ Purrs: 1, coat: 2, name: 'fred'},
runThroughMud = function() {
var superCat.runThroughMud =
{Purrs: 0, coat: 1}},
freeSpaday = function() {
var superCat.freeSpaday =
{Purrs: 2, coat:69}},
changeName = function() {
var supercat.changeName =
(name: '') }
// {
// var doggo = {// im really not getting it here and the dog question is just this with one more variable
// bark: function() {
// return this.sound
// },
// sound: 'wooof!'
// }
//write code here
}
}
Insert cell
var will ={ state: 'confusion', query : 'can I get a tutor', just_wants : 'to get a good grade and learn', stomach: 'empty', listening_to 'MCR, My Chemical Romance'}
Insert cell
Insert cell
Insert cell
superDoggo = function ()
{
var superDog =
{ Purrs: 1, coat: 2, name: 'fred'},
runThroughMud = function() {
var superDog.runThroughMud =
{Purrs: 0, coat: 1}},
freeSpaday = function() {
var superDog.freeSpaday =
{Purrs: 2, coat:69}},
changeName = function() {
var superDog.changeName =
(name: '') }
//Write Code here
}
return superDog
// }
// superCat = function() {
// var superCat =
Insert cell
Insert cell
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more