Making 42

Is it possible to make 42 from any number? While was h0g0, some people on the interim mailing list started seeing if they could make 42 from their researcher number by putting arithmetical operators inbetween the digits in the correct order (e.g. I am U51315, and (5 + 1) * (3 – 1 + 5) = 42). I decided to write a program to try and find such formulae automatically for any number, and here it is!

Currently it only handles two to five digits, and only basic arithmetic (+, -, *, /, modulus, plus power and square roots sometimes).

Please enter a number: