ee.Number.and

Returns 1 if and only if both values are non-zero.

שימושהחזרות
Number.and(right)מספר
ארגומנטסוגפרטים
זה: leftמספרהערך בצד ימין.
rightמספרהערך בצד שמאל.

דוגמאות

עורך הקוד (JavaScript)

print('Both 5 and 10 are not 0?', ee.Number(5).and(ee.Number(10)));  // 1
print('Both 5 and 0 are not 0?', ee.Number(5).and(ee.Number(0)));  // 0

הגדרת Python

מידע על Python API ועל שימוש ב-geemap לפיתוח אינטראקטיבי מופיע בדף Python Environment.

import ee
import geemap.core as geemap

Colab (Python)

# 1
print('Both 5 and 10 are not 0?', ee.Number(5).And(ee.Number(10)).getInfo())
# 0
print('Both 5 and 0 are not 0?', ee.Number(5).And(ee.Number(0)).getInfo())