let N = Int(readLine()!)!
let tasks = (0..<N).map{_ in readLine()!.characters.split(" ").map{Int(String($0))!}}.sort{$0[1]<$1[1]}
var ans = "Yes"
var time = 0
for arr in tasks {
    let (A, B) = (arr[0], arr[1])
    time += A
    if time > B {
        ans = "No"
        break
    }
}
print(ans)