I have tried using the .indexof method but I can't figure out why it won't work, as all I need is to find if a value exists in an array ?
final String subject = ((EditText)findViewById(R.id.subject)).getText().toString();
final String subjects[] ={"biology","business","chemistry","computer science","critical thinking",
"economics","english language", "english literature","further mathematics","geography",
"german","politics","history","ict","japanese","law", "mathematics","psychology",
"religious studies","sociology","spanish"};
final String creative_subjects[] ={"art and design","fine art", "dance","design and technology",
"design and textiles","fashion and textiles", "film studies ","music","performing arts",
"photography", "physical education","graphics"};
creative_subjects.indexOf(subject.toLowerCase());