title: Call Cost Calculator Python Exercise
body: <p>I'm taking a python class for beginners. However, I'm struggling with the below:</p>
  <p><strong>Description of exercise</strong></p>
  <p>Write a program that computes the cost of a long-distance call. The cost of the call is
  determined according to the following rate schedule:</p>
  <p>• Any call started between 8:00 A.M. and 6:00 P.M., Monday through Friday, is
  billed at a rate of $0.40 per minute.</p>
  <p>• Any call starting before 8:00 A.M. or after 6:00 P.M., Monday through Friday, is
  charged at a rate of $0.25 per minute.</p>
  <p>• Any call started on a Saturday or Sunday is charged at a rate of $0.15 per
  minute.</p>
  <p>The input will consist of the day of the week, the time the call started, and the length
  of the call in minutes.
  The output will be the cost of the call.</p>
  <p>Notes:</p>
  <ol>
  <li><p>The time is to be input as 4 digit number, representing the time in 24-hour
  notation, so the time 1:30 P.M. is input as 1330</p>
  </li>
  <li><p>The day of the week will be read as one of the following three character string:
  ‘Mon’, ‘Tue’, ‘Wed’, ‘Thr’, ‘Fri’, ‘Sat’ or ‘Sun’</p>
  </li>
  <li><p>The number of minutes will be input as a positive integer.</p>
  </li>
  </ol>
  <p>For example, an execution could look like this:</p>
  <p>Enter the day the call started at: Fri</p>
  <p>Enter the time the call started at (hhmm): 2350</p>
  <p>Enter the duration of the call (in minutes): 22</p>
  <p>This call will cost $5.50</p>
  <p><strong>The code I worked out:</strong></p>
  <pre><code>week = str(input(&quot;Enter the day call started at: &quot;))
  hour_started = int(input(&quot;Enter the time the call started at (hhmm): &quot;))
  duration = int(input(&quot;Enter the duration of the call (in minutes): &quot;))
  
  if(week == &quot;Mon&quot;) or (week == &quot;Tue&quot;) or (week == &quot;Wed&quot;) or (week == &quot;Thr&quot;) or (week == &quot;Fri&quot;):
      if(int(hour_started &gt; 1800) and int(hour_started &lt;= 2400)) or (int(hour_started &lt; 800) and int(hour_started &gt;= 0)):
       tarif2 = float(duration * 0.25)
       print(&quot;This call will cost &quot; + '$' + '%.2f' % float(tarif2), sep=&quot;&quot;)
      if(int(hour_started &gt;= 800) and int(hour_started &lt;= 1800)):
       tarif3 = float(duration * 0.40)
       print(&quot;This call will cost &quot; + '$' + '%.2f' % float(tarif3), sep=&quot;&quot;)
  else:
      tarif1 = float(duration * 0.15)
      print(&quot;This call will cost &quot; + '$' + '%.2f' % float(tarif1), sep=&quot;&quot;)
  </code></pre>
  <p>I know that my code doesn't import time module however, the task seems to not ask for such. The associated autograder is returning an error which seems to be not math but I/O related:</p>
  <pre><code>Test Failed: 'enter the day call started at:  this call will cost $5.50' != 'this call will cost $5.50'
  </code></pre>
  <p>Thank you so much for your help in advance!</p>