6 kyu

Secret Agent 101: The secret password

Description
Loading description...
Fundamentals
Algorithms
  • Please sign in or sign up to leave a comment.
  • yullieee Avatar

    super fun kata, thank you for your time!! ^c^

  • simone.ferrero Avatar

    This comment has been hidden.

  • matt c Avatar

    Needs some random test cases!

  • smile67 Avatar

    Perhaps the "decrypt- part" is not the best, see my solution;-)... made no issue, but have a look...

    • simone.ferrero Avatar

      Thanks for your feedback! That is a completely different approach than I had thought of, and it looks much better, although a little "outside" of the requirements in the description!

    • myjinxin2015 Avatar

      @smile67 Your code is too long, Man~~ hahah~~

    • smile67 Avatar

      :-) Yes, little bit more, but it's not my goal to produce the shortest code - "King of short, compressed and often difficult readable code";-)! It's always nice to see this very compressed code, but the shorter it is, the more it is difficult to read (generally). It's often marked as "Best Practice", i know, but who would really use this code in productive environment? Far away from "clean code" and often far away from "quick understanding" (by the way, my code here is also not the best and far away from my productive code which i did not on tablet;-)). Perhaps 95% aren't able to understand it or switch it away because it takes too long to get it. Isn't it better to produce code which is short (perhaps some lines more and perhaps because it's only hobby here and mostly nearby job), but readable for 95% included the "beginners";-)? And last but not least, the shorter it is, means not that it's better or quicker - to do something "once linear", perhaps with stack operations for example (don't know the problem) or to do something "20 times linear" with different regexp and often bad use of linq (which makes debugging and error handling not easier) is not always the best... Wow... much text:-)..., but i often thought about it while reading different code examples on codewars:-)... and perhaps 95% have a different opinion;-)... So keep smiling, everything is just for fun (here):-)!

    • smile67 Avatar

      @simone.ferrero: Yes i know (little bit "outside" the requirement), but sometimes it is the fun of it;-)... By the way a nice kata;-)!

    • simone.ferrero Avatar

      @smile67 Cheers mate :)