#
WC 1.3 Counting Tiles

Infinite number of tiles of length **1**, **2** and **3** are given to you.

In how many ways can you make a single tile of length **'n'** using the given tiles.

Given tiles can be added together to make bigger length tiles.

**Note:** One arrangement is different from another if length of tile used is different in atleast one position.

__Output Specifications:__

Give your answer as sum of answers for these **'n'** :

10

100

1000000

1000000000

12345654321

9999999999999999

**Note:** Give your answer modulo 1000000007(10^9 + 7) as it can be a large number.

Read more about modulo operation(%) here

__Examples:__

for n = 3, ans = 4

Possible combinations : 1+1+1, 1+2, 2+1, 3

for n = 5, ans = 13

__ IMPORTANT MESSAGE: __ **The correct solution for this question has been updated on 2nd July. Please try your previous solutions again. Any inconvenience caused is deeply regretted.**

Solution explanation link : link

### This challenge is worth 100 points.

### You must be logged in to submit a solution

View ranklist for this challenge

About scoring and submission