add States sample (contributed by Mark Rickert)