{"id":3534,"date":"2023-02-28T16:20:36","date_gmt":"2023-02-28T21:20:36","guid":{"rendered":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/?p=3534"},"modified":"2023-02-28T16:20:36","modified_gmt":"2023-02-28T21:20:36","slug":"javascript-functions-5b","status":"publish","type":"post","link":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/2023\/02\/28\/javascript-functions-5b\/","title":{"rendered":"JavaScript Functions (5B)"},"content":{"rendered":"<p>A Javascript function groups a combination of statements together and makes your code reusable. Functions can also be applied to math problems, such as finding the sum of a group of numbers or solving for distance in an equation. The majority of work will be contained in functions while the main program is just handling input and output. Every Javascript function is the same in that they all are passed zero or more pieces of information, have a name, and, normally, return a value. Excel functions, on the other hand, will return a value no matter what. There are a few extra steps when writing functions in Javascript. They require more parentheses as well as brackets. Similar to variables, we can\u2019t just name, or define, our function and leave it like that. It needs to be called. Normally, the function call is the name of the function, followed by more parentheses\u2013for example, sayHello() . By officially calling the function, it tells Javascript to execute the code.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A Javascript function groups a combination of statements together and makes your code reusable. Functions can also be applied to math problems, such as finding the sum of a group of numbers or solving for distance in an equation. The majority of work will be contained in functions while the main program is just handling [&hellip;]<\/p>\n","protected":false},"author":29446,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","footnotes":""},"categories":[10531],"tags":[845092],"class_list":{"0":"post-3534","1":"post","2":"type-post","3":"status-publish","4":"format-standard","6":"category-student-post","7":"tag-functions","8":"entry"},"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/posts\/3534","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/users\/29446"}],"replies":[{"embeddable":true,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/comments?post=3534"}],"version-history":[{"count":1,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/posts\/3534\/revisions"}],"predecessor-version":[{"id":3535,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/posts\/3534\/revisions\/3535"}],"wp:attachment":[{"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/media?parent=3534"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/categories?post=3534"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/community.mis.temple.edu\/mis2101sec730spring2023\/wp-json\/wp\/v2\/tags?post=3534"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}