title: Use of uninitialized value in print
body: <p>Please check this code. Getting Error </p>
  
  <pre><code>"Use of uninitialized value in print at 2.pl line 13, &lt;STDIN&gt; line 1."
  </code></pre>
  
  <p>Code:</p>
  
  <pre><code>#!/usr/bin/perl -w
  
  my %questions = (
      1 =&gt; "Java",
      2 =&gt; "Python",
      3 =&gt; "Perl",
      4 =&gt; "C"
  );
  print "Enter a number between 1 and 4:";
  my $selection = &lt;STDIN&gt;;
  print $questions{$selection};
  </code></pre>