-
Notifications
You must be signed in to change notification settings - Fork 0
Class1 newbranch #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: gh-pages
Are you sure you want to change the base?
Conversation
reneemeyer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DataTypes - nice job you need a few tweaks to your code. Also, in the future- a pull request should only have one assignment on it (every assignment gets it's own branch off of gh-pages)
01week/datatypes.js
Outdated
| function numStr(){ | ||
| var number = 27; | ||
| var a = number.toString(); | ||
| return a + a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix the indentation on line 38
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should also turn any number into a string, not just the number 27
01week/datatypes.js
Outdated
|
|
||
| function strNum(){ | ||
| var str = "27"; | ||
| var a = parseInt(str); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should turn any string into a number, not just the string '27'
01week/datatypes.js
Outdated
| var d = 27; | ||
| var e = Math.sqrt(-1); | ||
| var f = "Im having Fun"; | ||
| return [typeof a, b, c, d, e, typeof f] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should show the typeof of any argument that the function accepts. Don't hardcode variables
| const adding = (a, b) =>{ | ||
| // a = 7; | ||
| // b = 7; | ||
| return a + b |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, model all of your functions like this
01week/datatypes.js
Outdated
| var happiness = function(){ | ||
| var pizza = true; | ||
| var beer = true; | ||
| if(pizza && beer === true){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function hard codes two variables and if pizza evaluates to true and if beer is equal to the boolean true, it runs. I need a function to take into arguments and runs if they both evaluate to true.
01week/datatypes.js
Outdated
| //call the function | ||
|
|
||
|
|
||
| function kindaHappiness(){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comments on the happiness() function and apply.
01week/datatypes.js
Outdated
|
|
||
|
|
||
| function epicSadness(){ | ||
| var pizza = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comments on the happiness() function and apply.
reneemeyer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Jon, you're still off on the last three problems and your program construction. Go ahead and merge and we'll review in class.
Checkpoint Rubric
This is the rubric that your instructor will use to grade your checkpoints. Please do not edit.
Checkpoint 1
Checkpoint 2
Checkpoint 3