SharedPreferences를 사용하여 문자열 세트를 저장하려고 할 때의 오작동 SharedPreferencesAPI를 사용하여 문자열 집합을 저장하려고합니다 . Set s = sharedPrefs.getStringSet("key", new HashSet()); s.add(new_element); SharedPreferences.Editor editor = sharedPrefs.edit(); editor.putStringSet(s); edit.commit() 위의 코드를 처음 실행하면 s기본값 (방금 생성 된 끝 비어 있음 HashSet)으로 설정되어 문제없이 저장됩니다. 두 번째 및 다음에이 코드를 실행 s하면 첫 번째 요소가 추가 된 개체가 반환됩니다. 요소를 추가 할 수 있으며 프로그램 실행 중..