Pattern

Input


Sample code