         case (-5)...(5): color = UIColor(hue: 190.0/360.0, saturation: 0.84, brightness: 0.76, alpha: 1)
         default: color = UIColor.blackColor()
         }
+        
         }
         
         
     }
     
-    

        case 7: self.day = "SAT"
        default: self.day = "ERR"
        }

        var tempCelsius = degrees
        if unit == "°F" { tempCelsius = (degrees-32)/(9/5) }
        
        switch tempCelsius {
        case (35)...(300): color = UIColor(hue: 10.0/360.0, saturation: 0.74, brightness: 1, alpha: 1)


class WeatherCondition {
    
    //Properties needed by WeatherViewController
    var maxDegrees:Int
    var tempUnit:String
    var iconChar:String
    var day:String
    var color:UIColor
    
    var currDeg:Int?
        
    //Properties needed by DetailWeatherViewController
    var fullDay:String
    var minDegrees:Int
    var precipitation:Int
    var windSpeed:String
    var windUnit:String
    var description:String
    
    //Builds a WeatherCondition from certain API-Data
    init(maxDegrees:Double,units:String,icon:String,time:String, minDegrees:Double, windSpeed:Double, precipitation:Double, currDeg:Double?, description:String) {
        
        self.minDegrees = Int(minDegrees)
        self.maxDegrees = Int(maxDegrees)
        
        self.precipitation = Int(precipitation*100)
        
        self.windSpeed = String(format: "%.2f", windSpeed)
        
        if let currentDegrees = currDeg {self.currDeg = Int(currentDegrees)}
        
        self.description = description
        
        switch units {
        case "us":
            self.tempUnit = "°F"
            self.windUnit = "mp/h"
        default:
            self.tempUnit = "°C"
            self.windUnit = "km/h"
        }
        
        switch icon {
