there are any company name, its opening hours and days, for example,
ABC Corp. - Monday-Friday 10.00-18.00(or 10am-6pm)
Saturday 10am-3pm
how can i calculate in c the whole working hours of this company, if i`ve got function prototype int hours(char*)?
the result should be: ABC Corp. - 5(weekdays)*8(hours)+5(hours at weekends) = 45 hours
thanks for help