Warning: The magic method Slickr_Flickr_Plugin::__wakeup() must have public visibility in /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php on line 152

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831
{"id":25026,"date":"2015-10-28T17:49:35","date_gmt":"2015-10-28T23:49:35","guid":{"rendered":"https:\/\/ricardonewton.withknown.com\/2015\/wsq12---creating-c-functions"},"modified":"2015-10-28T17:49:35","modified_gmt":"2015-10-28T23:49:35","slug":"mastery12-creating-c-functions","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc101fall2015\/2015\/mastery12-creating-c-functions\/","title":{"rendered":"#Mastery12 – Creating C++ functions"},"content":{"rendered":"
\n

Hello! This is #Mastery12<\/a> about creating functions on c++. Actually, creating a function is pretty simple and easy to learn. First, let\u00b4s start defining a function. A function, is basically a group of commands arranged inside by a phrase or word that you choose. There are different kinds of functions. C++ has a list of different functions already made and available to use but you can always create your own too.<\/span><\/p>\n

\u00a0<\/span><\/p>\n

How to create a function? Very easy!<\/span><\/p>\n

The structure of a function consists in\u2026<\/span><\/p>\n

\u00a0\"\"<\/span><\/p>\n

A type\u00a0 <\/span>name ( conditions) { and coding that you want the function to proceed with<\/span><\/p>\n

\u00a0<\/span><\/p>\n

\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 <\/span><\/span><\/span>A type would be for example: long, double, or integer.<\/span><\/p>\n

\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 <\/span><\/span><\/span>The name can be almost anything you want, except for the ones already used by c++ to perform another task.<\/span><\/p>\n

\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 <\/span><\/span><\/span>The values are the things you are declaring.<\/span><\/p>\n

\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 <\/span><\/span><\/span>and then in between {} you have to type whatever you want the function to do.<\/span><\/p>\n

\u00a0<\/span><\/p>\n

Here is an example of a function:<\/span><\/p>\n

\u00a0<\/span><\/p>\n

A function is usually written before and outside the main( ). \u00a0<\/span>Functions are used to isolate different processes in a program. Here\u00b4s an example of a simple program; one that works with a function and one that doesn\u2019t and they both do the same.<\/span><\/p>\n

\u00a0\"\"\"\"<\/span><\/p>\n

There are different types of functions, for example void doesn\u2019t return any value. For functions that do return values there are different types like double, char, bool, string\u2026 When using functions that return values, make sure you make the compiler know to what value return like return a; or return x;<\/span><\/p>\n

\u00a0<\/span><\/p>\n

To call the function into the main() you can use a cout and type your function.<\/span><\/p>\n

\u00a0<\/span><\/p>\n

Here\u00b4s an example of a non-void function.<\/span><\/p>\n

<\/p>\n

\"\"\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 <\/span><\/span><\/p>\n

\u00a0 TIPS:<\/span><\/span><\/p>\n

– Remeber to maintain the same type in the same variables on your function.<\/span><\/span><\/p>\n

– Be careful with the braces and were to put them. Always close the function before typing the main( ).<\/span><\/span><\/p>\n

– Be careful with what values you want your function to return… Example: return a; or return 0;<\/span><\/span><\/p>\n

– Be aware that the function name you create can be used on c++ for another thing like main ( ).<\/span><\/span><\/p>\n

– Remeber that if the program compiles, it does not mean it works so make sure you test your program in the compiler.<\/span><\/span><\/p>\n

WATCH MY VIDEO\u00a0<\/span><\/span>https:\/<\/wbr>\/<\/wbr>youtu.be\/<\/wbr>NOLXBXg-yik<\/a><\/h2>\n<\/div>\n","protected":false},"excerpt":{"rendered":"
\n

Hello! This is #Mastery12<\/a> about creating functions on c++. Actually, creating a function is pretty simple and easy to learn. First, let´s start defining a function. A function, is basically a group of commands arranged inside by a phrase or word that you choose. There are different kinds of functions. C++ has a list of different functions already made and available to use but you can always create your own too.<\/span><\/p>\n

 <\/span><\/p>\n

How to create a function? Very easy!<\/span><\/p>\n

The structure of a function consists in…<\/span><\/p>\n

 \"\"<\/span><\/p>\n

A type  <\/span>name ( conditions) { and coding that you want the function to proceed with<\/span><\/p>\n

 <\/span><\/p>\n

       <\/span><\/span><\/span>A type would be for example: long, double, or integer.<\/span><\/p>\n

       <\/span><\/span><\/span>The name can be almost anything you want, except for the ones already used by c++ to perform another task.<\/span><\/p>\n

       <\/span><\/span><\/span>The values are the things you are declaring.<\/span><\/p>\n

       <\/span><\/span><\/span>and then in between {} you have to type whatever you want the function to do.<\/span><\/p>\n

 <\/span><\/p>\n

Here is an example of a function:<\/span><\/p>\n

 <\/span><\/p>\n

A function is usually written before and outside the main( ).  <\/span>Functions are used to isolate different processes in a program. Here´s an example of a simple program; one that works with a function and one that doesn’t and they both do the same.<\/span><\/p>\n

 \"\"\"\"<\/span><\/p>\n

There are different types of functions, for example void doesn’t return any value. For functions that do return values there are different types like double, char, bool, string… When using functions that return values, make sure you make the compiler know to what value return like return a; or return x;<\/span><\/p>\n

 <\/span><\/p>\n

To call the function into the main() you can use a cout and type your function.<\/span><\/p>\n

 <\/span><\/p>\n

Here´s an example of a non-void function.<\/span><\/p>\n

<\/p>\n

96<\/p>\n

<\/p>\n

Normal
\n 0<\/p>\n

21<\/p>\n

false
\n false
\n false<\/p>\n

ES-TRAD
\n X-NONE
\n X-NONE<\/p>\n

<\/p>\n

<\/p>\n

\/* Style Definitions *\/
\ntable.MsoNormalTable
\n\t{mso-style-name:”Tabla normal”;
\n\tmso-tstyle-rowband-size:0;
\n\tmso-tstyle-colband-size:0;
\n\tmso-style-noshow:yes;
\n\tmso-style-priority:99;
\n\tmso-style-parent:””;
\n\tmso-padding-alt:0cm 5.4pt 0cm 5.4pt;
\n\tmso-para-margin:0cm;
\n\tmso-para-margin-bottom:.0001pt;
\n\tmso-pagination:widow-orphan;
\n\tfont-size:12.0pt;
\n\tfont-family:Calibri;
\n\tmso-ascii-font-family:Calibri;
\n\tmso-ascii-theme-font:minor-latin;
\n\tmso-hansi-font-family:Calibri;
\n\tmso-hansi-theme-font:minor-latin;
\n\tmso-fareast-language:EN-US;}<\/p>\n

<\/p>\n

\"\"                      <\/span><\/span><\/p>\n

  TIPS:<\/span><\/span><\/p>\n

– Remeber to maintain the same type in the same variables on your function.<\/span><\/span><\/p>\n

– Be careful with the braces and were to put them. Always close the function before typing the main( ).<\/span><\/span><\/p>\n

– Be careful with what values you want your function to return… Example: return a; or return 0;<\/span><\/span><\/p>\n

– Be aware that the function name you create can be used on c++ for another thing like main ( ).<\/span><\/span><\/p>\n

– Remeber that if the program compiles, it does not mean it works so make sure you test your program in the compiler.<\/span><\/span><\/p>\n

WATCH MY VIDEO <\/span><\/span>https:\/\/youtu.be\/NOLXBXg-yik<\/a><\/h2>\n<\/div>\n","protected":false},"author":254,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,3],"tags":[186,129],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/25026"}],"collection":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/users\/254"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/comments?post=25026"}],"version-history":[{"count":1,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/25026\/revisions"}],"predecessor-version":[{"id":25027,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/25026\/revisions\/25027"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/media?parent=25026"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/categories?post=25026"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/tags?post=25026"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}