Under construction

Still being built. Things may change

Pick the Quadrant

Interview

Time limit1sMemory limit512 MB

Summary
Read the x and y coordinates of a nonzero point and print which of the four quadrants it lies in.
Level

Easy1 of 10

Topics
Implementation, Math
Solved
No attempts yet

Problem

Given a point, decide which quadrant it lies in. The quadrants are numbered 1 through 4 as in the picture below. "Quadrant n" in the picture means the n-th quadrant.

Quadrant numbering

For example, point A at (12,5)(12, 5) has a positive x coordinate and a positive y coordinate, so it lies in quadrant 1. Point B has a negative x coordinate and a positive y coordinate, so it lies in quadrant 2.

Write a program that reads the coordinates of a point and reports its quadrant. Both coordinates are either positive or negative, and zero never appears.

Input

The first line contains an integer xx. (−1000≤x≤1000-1000 \le x \le 1000, x≠0x \ne 0)

The second line contains an integer yy. (−1000≤y≤1000-1000 \le y \le 1000, y≠0y \ne 0)

Output

Print the number of the quadrant that contains the point (x,y)(x, y). The value is one of 1, 2, 3, 4.

Examples2

  1. Example 1

    Input
    12
    5
    
    Expected output
    1
    
  2. Example 2

    Input
    9
    -13
    
    Expected output
    4