myinput = raw_input(&quot;Please enter a binary real number:  &quot;)<br>myinput = myinput.split(&quot;.&quot;)<br><br>binstr1 = myinput[0]<br>binstr2 = myinput[1]<br><br>decnum1 = 0<br>decnum2 = 0<br><br>for i in binstr1:<br>
    decnum1 = decnum1 * 2 + int(i)<br><br>for k in binstr2:<br>    decnum2 = decnum2 * 2 + int(k)<br><br><br><br>print &quot;\nThe binary real number &quot;, binstr1, &quot;.&quot;, binstr2, &quot; converts to &quot;, decnum1,&quot;.&quot;,decnum2,&quot; in decimal.&quot;<br>
<br><br>that is what I have so far but I need to create a condition where I need only 10 sufficient numbers from the variable decnum2. I know I need something like<br>if len(decnum2) &gt; 11:<br>    decnum2 = decnum2[0:11]<br>
<br>but I keep getting unsubscriptable errors. I know it has to do with types but it&#39;s late and I just need some help. thank you in advance. - chris<br>