{"id":4807,"date":"2014-07-02T07:05:46","date_gmt":"2014-07-02T07:05:46","guid":{"rendered":"http:\/\/www.oracletutoring.ca\/blog\/?p=4807"},"modified":"2014-07-02T07:05:46","modified_gmt":"2014-07-02T07:05:46","slug":"summer-perl-programming-running-first-script-for-linux-mac-users","status":"publish","type":"post","link":"https:\/\/www.oracletutoring.ca\/blog\/summer-perl-programming-running-first-script-for-linux-mac-users\/","title":{"rendered":"Summer PERL programming:  running first script for Linux &#038; Mac users"},"content":{"rendered":"<h1>In the context of tutoring, a lazy summer day might mean academic pursuits at a relaxed pace.\u00a0 The tutor acknowledges the need to bring Linux and Mac users equal with Windows users:\u00a0 in this installment, he offers instructions for Linux and Mac users to execute their first PERL script.<\/h1>\n<p>In my <a href=\"?p=4766\">previous post<\/a> I instructed Windows users through the execution of their first PERL script.  Now, Linux and Mac users, it&#8217;s your turn.<\/p>\n<p>Open your text editor and type in the following:<\/p>\n<p><span style=\"color:brown;font-family:monospace\">#!\/usr\/bin\/perl<\/span><\/p>\n<p><span style=\"color:brown;font-family:monospace\">print &#8220;Hello, how are you?&#8211;from PERL!\\n\\n&#8221;;<\/span><\/p>\n<p>Let&#8217;s imagine you call your file <span style=\"font-family:monospace\">july101<\/span> and save it in your &#8220;My_perl_programs&#8221; folder.  In my experience, you can save it as type &#8220;all files&#8221; or type &#8220;text files&#8221; &#8211; just as long as it&#8217;s actually plain text.<\/p>\n<p>Now, open your terminal and go into your &#8220;My_perl_programs&#8221; directory.  Enter the command <span style=\"font-family:monospace\">ls<\/span> to make sure your file <span style=\"font-family:monospace\">july101<\/span> is listed.  Assuming you see it, enter the following command:<\/p>\n<p><span style=\"font-family:monospace\">perl july101<\/span><\/p>\n<p>If the process works, the terminal should reply with<\/p>\n<p><span style=\"font-family:monospace\">Hello, how are you?&#8211;from PERL!<\/span><\/p>\n<p>If you receive that greeting, congratulations!  You, Linux or Mac user, have successfully executed your first PERL script.<\/p>\n<p>The next few posts, we&#8217;ll review what we did during this one and last one.  To quote Phil Collins in his hit song <a href=\"http:\/\/en.wikipedia.org\/wiki\/Against_All_Odds_%28Take_a_Look_at_Me_Now%29\">Against All Odds<\/a>:<\/p>\n<p>&#8220;There&#8217;s so much I have to say to you\/So many reasons why&#8230;.&#8221;<\/p>\n<p>We&#8217;ll get to it all, in the coming days:)<\/p>\n<p>Jack of <a href=\"https:\/\/www.oracletutoring.ca\">Oracle Tutoring by Jack and Diane,<\/a> Campbell River, BC.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the context of tutoring, a lazy summer day might mean academic pursuits at a relaxed pace.\u00a0 The tutor acknowledges the need to bring Linux and Mac users equal with Windows users:\u00a0 in this installment, he offers instructions for Linux &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/www.oracletutoring.ca\/blog\/summer-perl-programming-running-first-script-for-linux-mac-users\/\"> <span class=\"screen-reader-text\">Summer PERL programming:  running first script for Linux &#038; Mac users<\/span> Read More &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[105],"tags":[167,168],"class_list":["post-4807","post","type-post","status-publish","format-standard","hentry","category-computer-science","tag-getting-started-with-perl","tag-programming-with-perl"],"_links":{"self":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/4807","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/comments?post=4807"}],"version-history":[{"count":24,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/4807\/revisions"}],"predecessor-version":[{"id":4831,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/4807\/revisions\/4831"}],"wp:attachment":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/media?parent=4807"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/categories?post=4807"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/tags?post=4807"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}