module ExerciseAdvice
Constants
- VERSION
Public Class Methods
exercise(weightstatus,preference)
click to toggle source
Your code goes hereā¦
# File lib/ExerciseAdvice.rb, line 8 def self.exercise(weightstatus,preference) if weightstatus == "underweight" && preference == "cardio" cardio="walking", cardiotime=45, weights="leg press", weightstime=30, streching="yoga", streching_time=30 elsif weightstatus == "underweight" && preference == "weights" cardio="walking", cardiotime=30, weights="leg press", weightstime=45, streching="yoga", strechingtime=30 elsif weightstatus == "underweight" && preference == "streching" cardio="walking", cardiotime=30, weights="leg press", weightstime=30, streching="yoga", strechingtime=45 elsif weightstatus == "Normal weight" && preference =="cardio" cardio="walking", cardiotime=45, streching="crunches", strechingtime=15, weights="leg press", weightstime=15 elsif weightstatus == "Normal weight" && preference =="streching" cardio="walking", cardiotime=15, streching="crunches", strechingtime=45, weights="leg press", weightstime=15 elsif weightstatus == "Normal weight" && preference =="weights" cardio="walking", cardiotime=15, streching="crunches", strechingtime=15, weights="leg press", weightstime=45 elsif weightstatus == "Over weight" && preference =="cardio" cardio="walking", cardiotime=45, streching="yoga", strechingtime=30, weights="dead lifts", weightstime=30 elsif weightstatus == "Over weight" && preference=="streching" cardio="walking", cardiotime=30, streching="yoga", strechingtime=45, weights="dead lifts", weightstime=30 elsif weightstatus == "Over weight" && preference=="weights" cardio="walking", cardiotime=45, streching="yoga", strechingtime=30, weights="dead lifts", weightstime=45 elsif weightstatus == "Obese" && preference=="cardio" cardio="walking", cardiotime=60, streching="yoga", strechingtime=45, weights="military press", weightstime=45 elsif weightstatus == "Obese" && preference=="streching" cardio="walking", cardiotime=45, streching="yoga", strechingtime=60, weights="military press", weightstime=45 elsif weightstatus == "Obese" && preference=="weights" cardio="walking", cardiotime=45, streching="yoga", strechingtime=45, weights="military press", weightstime=60 end end