{"id":1287,"date":"2016-09-16T20:34:54","date_gmt":"2016-09-16T20:34:54","guid":{"rendered":"http:\/\/blog.paranoidprofessor.com\/?p=1287"},"modified":"2016-09-17T18:53:54","modified_gmt":"2016-09-17T18:53:54","slug":"thinking-like-a-programmer","status":"publish","type":"post","link":"https:\/\/blog.paranoidprofessor.com\/index.php\/2016\/09\/16\/thinking-like-a-programmer\/","title":{"rendered":"computer programs in the 21st century"},"content":{"rendered":"<blockquote>\n<h2 style=\"text-align: center;\">The app I downloaded just doesn&#8217;t work. \u00a0I am missing a lot of the photos that I took.<\/h2>\n<\/blockquote>\n<p style=\"text-align: left;\">Great! \u00a0I am at home and it looks like work has somehow followed me.<\/p>\n<p>That great application that my wife was bragging about the previous day was now causing her great distress. \u00a0The four hours she spent photographing created an incomplete list of files.<\/p>\n<p>The application allows you to use your camera to take photos of photos in your physical photo album. \u00a0The application crops the photo and uploads them to their server. \u00a0You can then download the photos to your laptop.<\/p>\n<p>The first day every photo showed up online annotated with all of her notes. \u00a0The second day approximately half of the photos that she took were missing. \u00a0She wasn&#8217;t sure which photos \u00a0went missing but it might have been the photos from the end of her photo session.<\/p>\n<p>A few things popped into my head. \u00a0Is it possible that this free service only shows the first 500 photos. \u00a0Nope, that wasn&#8217;t it.<\/p>\n<p>She downloaded everything and deleted everything and tried again. \u00a0This time some files were showing up while others were missing. \u00a0The harder she tried the more photos were missing.<\/p>\n<p>I gave it some thought and the facts of the problem was that the photographs were not being stored in the normal photo album. \u00a0Not the ones that were lost nor the ones that were successful. \u00a0I watched and could see that she was taking more than one photo a minute.<\/p>\n<p>My idea was perhaps these &#8220;temporary files&#8221; are being stored elsewhere but rather than using the built in naming convention the app developers decided to be clever. \u00a0Maybe they were taking their own naive approach to naming them. Maybe they used the same name for the current ph0to?<\/p>\n<p>Sure enough, when my wife took no more than a single photo a minute then all of a sudden everything worked perfectly. \u00a0No more pictures got lost.<\/p>\n<p>The wife is once again happy. \u00a0The key is to think like a programmer, the good ones not the lazy ones.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The app I downloaded just doesn&#8217;t work. \u00a0I am missing a lot of the photos that I took. Great! \u00a0I am at home and it looks like work has somehow followed me. That great application that my wife was bragging &hellip; <a href=\"https:\/\/blog.paranoidprofessor.com\/index.php\/2016\/09\/16\/thinking-like-a-programmer\/\">Continue reading <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":[],"categories":[4],"tags":[24],"_links":{"self":[{"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/posts\/1287"}],"collection":[{"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/comments?post=1287"}],"version-history":[{"count":4,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/posts\/1287\/revisions"}],"predecessor-version":[{"id":1291,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/posts\/1287\/revisions\/1291"}],"wp:attachment":[{"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/media?parent=1287"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/categories?post=1287"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.paranoidprofessor.com\/index.php\/wp-json\/wp\/v2\/tags?post=1287"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}