spymaster Posted January 4, 2013 Share Posted January 4, 2013 hi guys, need help with this question... A PHP function countResponses is to be defined that will take an array of feedback statements and return the number of times that a particular statement has occurred. $responses=array('Outstanding','Outstanding','MostlyOK','Dull','Outstanding'); print "No is ".countResponse('Outstanding',$responses); Complete the definition of countResponse below. function countResponse( ) { $countNumber=0; foreach( ) { if( ) { }; }; return ; } thanks in advance! Quote Link to comment https://forums.phpfreaks.com/topic/272690-need-some-help-with-countresponse/ Share on other sites More sharing options...
Muddy_Funster Posted January 4, 2013 Share Posted January 4, 2013 why not just go ask your tutor? Quote Link to comment https://forums.phpfreaks.com/topic/272690-need-some-help-with-countresponse/#findComment-1403187 Share on other sites More sharing options...
spymaster Posted January 4, 2013 Author Share Posted January 4, 2013 why not just go ask your tutor? i have none Quote Link to comment https://forums.phpfreaks.com/topic/272690-need-some-help-with-countresponse/#findComment-1403193 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.