arr007.hs 188 Bytes
Newer Older
1
2
3
4
-- !!! Array - accessing empty arrays
-- 
-- empty arrays are legal, but indexing them is undefined!
--
5
import Data.Array
6
7
8
9
10
11

main =
 let 
  a1 = array (1::Int,0) [(1,'a')]
 in
 print (a1!0)