#include using Int = int64_t; void Solve() { Int n; std::cin >> n; std::vector a(n); Int positive = 0; Int negative = 0; Int positive_max = 0; Int negative_max = 0; for (Int i = 0; i < n; ++i) { std::cin >> a[i]; if (0 < a[i]) { positive += a[i]; positive_max = std::max(positive_max, a[i]); } else if (a[i] < 0) { negative += -a[i]; negative_max = std::max(negative_max, -a[i]); } } if (negative - negative_max <= positive_max && positive - positive_max <= negative_max) { std::cout << "Yes\n"; } else { std::cout << "No\n"; } } int main() { std::ios::sync_with_stdio(false); std::cin.tie(nullptr); Solve(); }