Java Program.
You are also super excited and you wish to buy roses of 3 different colors. You always buy roses in order, white, yellow, red.
So if you buy 7 roses, they will be "white, yellow, red, white, yellow, red, white".
You need to find the number of yellow roses that you will buy?
Input:-
The only line of input contains a single integer, N, the number of roses that you will buy.
Constraints
1 <= N <= 1000
Output:-
Output a single integer, the number of yellow roses.
Sample Input 1
2
Sample Output 1
1
Sample Input 2
8
Sample Ouput 2
3
Answers
Answered by
1
Answer:
Explanation:
⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀ ⠀ ⠀⠀⠀⠀⠀⠀ ⠀⠀ ⠀ ⠀⠀⠀⠀
Similar questions