amykarnaze / mod_0_skills

0 stars 0 forks source link

Assessment Results #1

Open francepack opened 4 years ago

francepack commented 4 years ago

@amykarnaze You performed well enough on the assessment to merit a chance to make some changes that can promote you to technical ready. Please make the following updates by EOD Saturday:

Let me know if you have questions about this feedback!

amykarnaze commented 4 years ago

I changed the class names to pascalCase.. oops!

drinkMenu forestRoom5DrinkMenu rocksGlass libbyGlass100100

I see now that glass could be any type of glass :/!! I changed it to a rocksGlass and kept the same object as a libbyGlass#. I added ice boolean and straw boolean attributes. Methods- useStraw (modifies straw attribute to true and modifies the contents array to include straw) and addIce (modifies the ice attribute to true and contents array to include ice) methods. I was wondering about a boolean for a servedUp attribute. This means, the rocks glass could be served martini style (shaken) with no ice. Would it be as simple as servedUp is false? Which would modify the ice boolean attribute to true and the contents array attribute to include ice (my new attribute and method)?

For the menu, I was thinking a multiple page/book style menu that requires being open to read (just so you know where my thinking was at). I added a pictures array (addPicture modifies contents of pictures array) and a menuSpecial boolean (where the addSpecial method modifies menuSpecial to true of false).

Let me know if there is anything else I can do better!

Thanks so much, Mason!!

francepack commented 4 years ago

@amykarnaze Could you make a commit and push to this repo with the updated changes? Also, make sure to look up PascalCase if you haven't - it is used specifically for names of classes. Well done with the casing for classes and methods.

For your idea about a servedUp method- I think that works well! I may name it isServedUp... that is a convention you may see out there that makes it very easy to tell the purpose of a boolean attribute.

I'm really liking these ideas! Just make a push up to github when you have a sec so I can double check.

amykarnaze commented 4 years ago

I just realized I have been using camelCase. We were using mostly snake_case in class and I was nervous about switching for the assessment and I think I thought camelCase and PascalCase were the same thing, and one being an animal, welp the animal won out..!

amykarnaze commented 4 years ago

I guess I am confused about why we use PascalCase? I reviewed some lectures and feel like they used snake_case or camelCase mostly, but must have missed something. Is it important for naming a class and object? I changed to PascalCase and pushed!

francepack commented 4 years ago

@amykarnaze Great question! Attributes and methods tend to be named in the conventions of the language you are coding in. So since you are learning JavaScript, we are having you use camel case. That may also be why you have seen snake case examples- the back enders use that for Ruby. Class names, however, tend to be in Pascal case across different languages. I can't say 100% all coding languages use that convention, but many do, and it is just a very easy way for developers to recognize something as a class despite whatever syntax or naming conventions are used around it.