sub create_time_machine { my $time_duration = shift; my $wormhole = sub { # (Creation of wormhole is left as an exercise :-) # ... }; # Here, implement the following pseudocode: # Tow wormhole close enough to the neutron # star, and for a long enough period, to # fix its duration at $time_duration years... return $wormhole; } # Now create time machine with desired time period my $p = create_time_machine(1_000); # eg. 1,000 years