Fragments: Use switch statements over if else statements for legibility

Updated README