// faking an array in Preferences

// array notation
userPrefs.putInt( "fruits", 3 );
userPrefs.put( "fruit[0]", "apple" );
userPrefs.put( "fruit[1]", "peach" );
userPrefs.put( "fruit[2]", "strawberry" );

// or underscore
userPrefs.putInt( "fruits", 3 );
userPrefs.put( "fruit_0", "apple" );
userPrefs.put( "fruit_1", "peach" );
userPrefs.put( "fruit_2", "strawberry" );

// or composite
userPrefs.put( "fruit", "apple,peach,strawberry" );