• Sign Up
    Time to claim your honor
  • Training
  • Practice
    Complete challenging Kata to earn honor and ranks. Re-train to hone technique
  • Freestyle Sparring
    Take turns remixing and refactoring others code through Kumite
  • Community
  • Leaderboards
    Achieve honor and move up the global leaderboards
  • Chat
    Join our Discord server and chat with your fellow code warriors
  • Discussions
    View our Github Discussions board to discuss general Codewars topics
  • About
  • Docs
    Learn about all of the different aspects of Codewars
  • Blog
    Read the latest news from Codewars and the community
  • Log In
  • Sign Up
carlos.pantelides Avatar
Name:carlos.pantelides
Clan:BBVA
Member Since:Mar 2017
Last Seen:Jul 2024
Profiles:
    Following:2,436
    Followers:2,443
    Allies:2,384
    View Profile Badges
    • Stats
    • Kata
    • Collections
    • Kumite
    • Social
    • Discourse
    • Conversations (35)
    • Replies
    • Authored
    • Needs Resolution
    • Custom User Avatar
      • argigeek
      • commented on "Sort Numbers" rust solution
      • 3 years ago

      fetch! i didn't and I see that it was for lack of ";\nsorted"

      the compiler said that it was ()

    • Custom User Avatar
      • gevera
      • commented on "Dollars and Cents" elixir solution
      • 4 years ago

      Yeah. It was unfortunately deprecated. Beautiful solution though

    • Custom User Avatar
      • WFran
      • commented on "Grasshopper - Summation" elixir solution
      • 6 years ago

      Beware of big numbers, tail-call optimization is not used here! For more information about Elixir tail-call optimization, read the official docs regarding recursion https://elixir-lang.org/getting-started/recursion.html where (at the moment of writing) is a link to the wikipedia "tail-call" page.

    • Custom User Avatar
      • carlos.pantelides
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      The useless

      int cmd = std::stoi(packet.substr(4,4));

      was the problem, when an invalid base 10 command is received, an exception is thrown.

      I won't try, but I'm sure all the solutions I'd tried were rigth

      Thank you

      Seeya

    • Custom User Avatar
      • FArekkusu
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      I've just checked it, and according to this SO question starting from C++ 11 string are immutable objects (as I thougt from the beginning).

      Trying using int -> string conversions and string concatenation instead.

    • Custom User Avatar
      • Polar
      • resolved a question on "String Packet Based Communications" kata
      • 7 years ago

      I totally agree with your logic, copying your example in its entirity and using the g++ compiler runs and produces the correct result without issue.

      This is certainly an issue with how the code is compiled/run in the Kata environment, and not a product of the kata itself.

      I will mark this as resolved for now, but please feel free to continue the discussion :)

    • Custom User Avatar
      • carlos.pantelides
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      This comment is hidden because it contains spoiler information about the solution

    • Custom User Avatar
      • FArekkusu
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      You can add char and int because char is int (partially).

      I'm not sure, but I have an insane theory that after mutating the string like you are doing, something really bad happens to it. Try using working with a string as if it was a string (and not a char array (duh)), and I think it may work then.

    • Custom User Avatar
      • carlos.pantelides
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      This comment is hidden because it contains spoiler information about the solution

    • Custom User Avatar
      • Polar
      • resolved a suggestion on "String Packet Based Communications" kata
      • 7 years ago

      Resolved.

    • Custom User Avatar
      • Polar
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      Approved, thank you for your contribution!

    • Custom User Avatar
      • Polar
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      This is your issue:

      out[8] = '0' + result % 10;

      You are trying to add together a character and an integer.

      Please let me know if your solution works and I will mark this as resolved.

      Ps. The way that you are checking for the instruction is clever!

    • Custom User Avatar
      • donaldsebleung
      • created a suggestion for "String Packet Based Communications" kata
      • 7 years ago

      NASM Translation Kumited - please accept :D

    • Custom User Avatar
      • carlos.pantelides
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      This comment is hidden because it contains spoiler information about the solution

    • Custom User Avatar
      • Polar
      • commented on "String Packet Based Communications" kata
      • 7 years ago

      Could you share what you have? Mark it with a spoiler flag please thanks!

    • Loading more items...
    • © 2025 Codewars
    • About
    • API
    • Blog
    • Privacy
    • Terms
    • Code of Conduct
    • Contact

    Confirm

    • Cancel
    • Confirm

    Collect: undefined

    Loading collection data...