Änderung des Weltzustandes
data World = ... data IO a = IO ( World -> (a, World) )
das Welt-Objekt bezeichnet Welt außerhalb des Programmes
f :: World -> ( World, World ) f w = ( putStr "foo" w, putStr "bar" w )Lösungen:
World ist privat,
  öffentlich ist nur IO
World ist öffentlich,
  aber unique (nicht verdoppeln, nicht löschen)