• 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
jamescurran Avatar
Name:James Curran
Clan:Nomads
Member Since:Oct 2017
Last Seen:Oct 2024
Profiles:
Following:13
Followers:12
Allies:12
View Profile Badges
  • Stats
  • Kata
  • Collections
  • Kumite
  • Social
  • Discourse
  • Conversations
  • Replies
  • Authored (75)
  • Needs Resolution
  • Custom User Avatar
    • jamescurran
    • commented on "Sum Strings as Numbers" csharp solution
    • 2 years ago

    The problem here is that the line

    strReturn = bitCurrent + strReturn;

    is grossly inefficent. (It first creates a string out of the int, then concatenates it with the existing string, creating yet another string. I'd guess about 90% of the execution time is this routine would be on just that line.

  • Custom User Avatar
    • jamescurran
    • commented on "Remove duplicate words" csharp solution
    • 3 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Money Match: Double or Nothing" javascript solution
    • 3 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Student's Final Grade" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Simple multiplication" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Square Every Digit" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Mutual Recursion" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Mutual Recursion" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Remove String Spaces" csharp solution
    • 4 years ago

    strings are an IEnumerable. The ToCharArray() is unnecessary.

  • Custom User Avatar
    • jamescurran
    • commented on "Remove String Spaces" csharp solution
    • 4 years ago

    What makes you think the Replace() would leave spaces on the start or end?

  • Custom User Avatar
    • jamescurran
    • commented on "Remove String Spaces" csharp solution
    • 4 years ago

    It's not redundant, just bad form. input[i] is a char, " " is a string. The line should be "if (input[i] == ' ')" or better "if (Char.IsWhiteSpace(input[i]))"

  • Custom User Avatar
    • jamescurran
    • commented on "Remove First and Last Character" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Statistics for an Athletic Association" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Descending Order" csharp solution
    • 4 years ago

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

  • Custom User Avatar
    • jamescurran
    • commented on "Mumbling" csharp solution
    • 4 years ago

    Nice to preallocate the StringBuilder, but why are you dragging floating point into the calculation? The result has to be an integer, so you might as well, do everything in integer math.

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

Confirm

  • Cancel
  • Confirm

Collect: undefined

Loading collection data...