{"id":126,"date":"2010-01-23T07:22:47","date_gmt":"2010-01-23T12:22:47","guid":{"rendered":"http:\/\/zitstif.no-ip.org\/?p=126"},"modified":"2010-01-23T07:23:18","modified_gmt":"2010-01-23T12:23:18","slug":"cool-perl-prompt","status":"publish","type":"post","link":"http:\/\/zitstif.no-ip.org\/?p=126","title":{"rendered":"Cool Perl prompt"},"content":{"rendered":"<pre lang=\"perl\">#!\/usr\/bin\/env perl\r\n\r\ndo\r\n  {\r\n     print \"perl#: \";\r\n     chop($_ = <>);\r\n     eval($_);\r\n  }\r\nwhile ($_ ne \"exit\")\r\n<\/pre>\n<p>There are times when I get an itching to start writing perl programs and tonight was no exception. I was curious as to how perl handled exceptions and so forth. After doing some reading on line I found a merely 9 lines of code that will serve you as an interactive perl prompt (think typing in python without any arguments.. and you&#8217;ll understand what I&#8217;m saying, or just give this piece of code a try yourself.)<\/p>\n<p><a title=\"http:\/\/feyd.ldc.usb.ve\/docs\/perl\/practical-perl\/www.cs.cf.ac.uk\/Dave\/PERL\/node114.html\" href=\"http:\/\/feyd.ldc.usb.ve\/docs\/perl\/practical-perl\/www.cs.cf.ac.uk\/Dave\/PERL\/node114.html\" target=\"_blank\">http:\/\/feyd.ldc.usb.ve\/docs\/perl\/practical-perl\/www.cs.cf.ac.uk\/Dave\/PERL\/node114.html<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>#!\/usr\/bin\/env perl do { print &#8220;perl#: &#8220;; chop($_ = ); eval($_); } while ($_ ne &#8220;exit&#8221;) There are times when I get an itching to start writing perl programs and tonight was no exception. I was curious as to how perl handled exceptions and so forth. After doing some reading on line I found a &hellip; <a href=\"http:\/\/zitstif.no-ip.org\/?p=126\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Cool Perl prompt<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11,3],"tags":[21,20],"class_list":["post-126","post","type-post","status-publish","format-standard","hentry","category-code","category-posts","tag-perl","tag-perl-prompt"],"_links":{"self":[{"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/posts\/126","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=126"}],"version-history":[{"count":8,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/posts\/126\/revisions"}],"predecessor-version":[{"id":134,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=\/wp\/v2\/posts\/126\/revisions\/134"}],"wp:attachment":[{"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=126"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=126"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/zitstif.no-ip.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=126"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}