Recognize ASCII art numbers
APL (87 85)

1-⍨⊃⍒(,↑{7↑'*'=⍞}¨⍳7)∘(+.=)¨{49↑,(16/2)⊤⎕UCS⍵}¨↓10 3⍴'嵝䍝뫂傁ဣ␋䠁䊫낫䢝䊅넂垵僡ᑨ嘙쐅嘹䜝䪀슪퀪岹亝尵䌧뮢'


Explanation:

Each possible ASCII number is encoded in 48 bits. (The 49th bit is always zero anyway). The string 嵝䍝뫂傁ဣ␋䠁䊫낫䢝䊅넂垵僡ᑨ嘙쐅嘹䜝䪀슪퀪岹亝尵䌧뮢 has three characters per ASCII number, each of which encodes 16 bits.


↓10 3⍴: split the data string into 10 3-char groups, each of which encodes a number.
{...}¨: for each of the groups:

(16/2)⊤⎕UCS⍵: get the first 16 bits of each of the three characters
,: concatenate the bit arrays into one array
49↑: take the first 49 elements. There are only 48, so this is equivalent to adding a 0 at the end.

,↑{7↑'*'=⍞}¨⍳7: read 7 lines of 7 characters from the keyboard, make a bit array for each line where 1 means the character was a *, and join them together.
(+.=)¨: for each possible digit, calculate how much bits the input had in common with the digit.
⍒: get the indices for a downwards sort of that list, so that the first item in the result is the index of the largest number in the previous list.
⊃: take the first item, which is the index of the digit
1-⍨: subtract one, because APL indices are 1-based.