#CCBCHBON0000003. Bỏ bội của ba (Skip Multiples of Three)
Bỏ bội của ba (Skip Multiples of Three)
Skip Multiples of Three
Source: Phước Hưng OJ
Version: Phuoc Hung OJ Extended
Problem Statement
Given nonnegative , inspect integers 1 through . Skip values divisible by 3, printing every remaining value on its own line. continue skips only the current iteration. Print nothing if .
Input
One line contains integer .
Output
Print qualifying integers in increasing order, one per line; empty output for .
Subtasks
-
Subtask 1 (20%): .
-
Subtask 2 (30%): .
-
Subtask 3 (50%): .
Examples
Example 1
Input:
5
Output:
1
2
4
5
Explanation:
Skip multiples of three and print the remaining integers one per line.
Example 2
Input:
0
Output:
Explanation:
Skip multiples of three and print the remaining integers one per line.