答案
def main():
import sys
input = sys.stdin.read
data = input().strip().split()
x1, y1, x2, y2, x3, y3, x4, y4 = map(int, data)
# 計算重疊矩形的座標
leftX = max(x1, x3)
bottomY = max(y1, y3)
rightX = min(x2, x4)
topY = min(y2, y4)
# 確認重疊區域是否形成有效的矩形
if leftX < rightX and bottomY < topY:
# 計算重疊面積
area = (rightX - leftX) * (topY - bottomY)
print(area)
else:
# 無重疊或重疊不形成有效的矩形區域
print("banana")
if __name__ == "__main__":
main()