Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function [x ans] = killme(n)
- ans = 0;
- x = 0;
- while ans == 0
- x = x+1;
- ihatemylife = num2str(x*n);
- if length(strfind(ihatemylife,'0'))+length(strfind(ihatemylife,'1')) == length(ihatemylife)
- ans = x*n;
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement