UVa 10862

From Algorithmist
Jump to: navigation, search

Contents

[edit] 10862 - Connect the Cable Wires

[edit] Summary

To find number of ways to connect a center with many houses with cables directly or via houses.

[edit] Explanation

Take paper and pencil and draw all the cable connection possibilities for the first few number of houses. The result should somewhat resemble the Fibonacci Sequence.

[edit] Notes

  • The output for any given case will be at most 900 digits.

[edit] Input

1
2
3
20
0

[edit] Output

1
3
8
102334155
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox