807 views
2 2 votes
An airline runs flights between several cities of the world. Every flight connects two cities. A millionaire wants to travel from Chennai to Timbuktu by changing at most $k_1$ flights. Being a millionaire with plenty of time and money, he does not mind revisiting the same city multiple times, or even taking the same flight multiple times in his quest. Can you help the millionaire by describing how to compute the number of ways he can make his journey? How many steps does your procedure take if there are $n$ cities and he can change flights at most $k_1$ times. You can assume that the procedure can add or multiply two numbers in a single operation.

1 Answer

Position:
Show:

Related questions

3 3 votes
1 1 answer
910
910 views
go_editor asked May 27, 2016
910 views
There is a thin, long and hollow fibre with a virus in the centre. The virus occasionally becomes active and secretes some side products. The fibre is so thin that new si...
4 4 votes
2 2 answers
1.3k
1.3k views
go_editor asked May 27, 2016
1,286 views
Consider the code below, defining the functions $f$ and $g$:f(m, n) { if (m == 0) return n; else { q = m div 10; r = m mod 10; return f(q, 10*n + r); } } g(m, n) { if (n ...
5 5 votes
2 2 answers
998
998 views
go_editor asked May 27, 2016
998 views
Consider the code below, defining the functions $f$ and $g$:f(m, n) { if (m == 0) return n; else { q = m div 10; r = m mod 10; return f(q, 10*n + r); } } g(m, n) { if (n ...
2 2 votes
2 2 answers
1.0k
1.0k views
go_editor asked May 27, 2016
1,047 views
Consider the code below, defining the functions $f$ and $g$:f(m, n) { if (m == 0) return n; else { q = m div 10; r = m mod 10; return f(q, 10*n + r); } } g(m, n) { if (n ...