Write code to add two numbers, 5 and 7. Then display the sum on the serial monitor.

Question

Write code to add two numbers, 5 and 7. Then display the sum on the serial monitor.

in progress 0
Thu Nguyệt 5 days 2021-07-22T21:00:58+00:00 1 Answers 1 views 0

Answers ( )

    0
    2021-07-22T21:02:03+00:00

    Answer:

    Explanation

    Using the Python 3 syntax in writing the code.

    First we will define a function ‘add_numbers’, parse in the variables x and y and return its sum as shown.

    Then we carry out the addition of 5 and 7.

    def sum_numbers(x, y):

    return x+y

    sum_numbers(5, 7)

Leave an answer

Browse

Giải phương trình 1 ẩn: x + 2 - 2(x + 1) = -x . Hỏi x = ? ( )