• 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
isqua Avatar
Name:isqua
Clan:Yandex
Member Since:Aug 2015
Last Seen:Aug 2024
Profiles:
Following:154
Followers:584
Allies:143
View Profile Badges
  • Stats
  • Kata
  • Collections
  • Kumite
  • Social
  • Discourse
  • Conversations (1268)
  • Replies
  • Authored
  • Needs Resolution
  • Custom User Avatar
    • hobovsky
    • commented on "Find the unique number" kata
    • 11 days ago

    what it wants from me?

    It is theoretically possible that your code will go through your function without doing any return, and C++ does not like this. It is not possible in this challenge because all inputs are guaranteed to have a valid answer, but C++ compiler does not know this, and it needs to have a return at every path. You can fix it by adding return 0; at the end of your function.

    how can i fully understand a problem with my code if it doesn't show me the full vector?

    You can use std::cout in your solution and print the vector to the console, but I agree this can be tedious in C++. Ideally, tests would show the vector, but they don't.

    But even when you add missing return, and when you check the vector, and you will try to reproduce the error, it is possible that your code will work for you. The bug in your code can be subtle and difficult to debug, and it's caused by out of bounds access: sometimes, your code accesses invalid memory before the vector, and sometimes after the vector, and this can be a bug difficult to reproduce.

  • Custom User Avatar
    • MrBenis
    • commented on "Find the unique number" kata
    • 11 days ago

    I don't understand what it wants from me??? ./solution.cpp:10:1: warning: control may reach end of non-void function [-Wreturn-type]. And next question - how can i fully understand a problem with my code if it doesn't show me the full vector? Wrong answer for 5 elements!
    Expected: equal to 0.55
    Actual: 1

  • Custom User Avatar
    • FranzMartyn
    • created a suggestion for "Find the unique number" kata
    • 13 days ago

    Groovy Translation

  • Custom User Avatar
    • kolonatalie
    • commented on "Find Maximum and Minimum Values of a List" javascript solution
    • 17 days ago

    Very clean solution!

  • Custom User Avatar
    • Chrono79
    • commented on "Find the unique number" kata
    • 19 days ago

    If that's the last sample test, you probably deleted the 10 where there is no number there, backup your code, click Reset, and paste it again.

  • Custom User Avatar
    • pedromattar42
    • commented on "Find the unique number" kata
    • 20 days ago

    assert.strictEqual(findUniq([ 3, , 3, 3, 3 ]), 10);

    why should this test case return 10???

  • Custom User Avatar
    • JohanWiltink
    • resolved a question on "Find the unique number" kata
    • 22 days ago
  • Custom User Avatar
    • JohanWiltink
    • resolved a question on "Find the unique number" kata
    • 22 days ago
  • Custom User Avatar
    • shadowimpostor
    • commented on "Find the unique number" kata
    • 22 days ago

    im too slow how unfortuhnate

  • Custom User Avatar
    • JohanWiltink
    • resolved a question on "Find the unique number" kata
    • 22 days ago
  • Custom User Avatar
    • JohanWiltink
    • resolved a question on "Find the unique number" kata
    • 22 days ago
  • Custom User Avatar
    • JohanWiltink
    • resolved an issue on "Find the unique number" kata
    • 22 days ago

    This issue is useless without mentioning which language is lacking this testcase. Closing.

  • Custom User Avatar
    • ejini战神
    • resolved a question on "Find the unique number" kata
    • 22 days ago

    Yes, if you do a 2-loop checking every combination possible... Though you can find more O(NLogN) and O(N) solutions in the solution tab ^^

  • Custom User Avatar
    • lotheravanti
    • commented on "Find the unique number" kata
    • last month

    Great Kata!

  • Custom User Avatar
    • Devin William Sumbaluwu
    • created a question for "Find the unique number" kata
    • last month

    Can the solution have O(n²) time complexity?

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

Confirm

  • Cancel
  • Confirm

Collect: undefined

Loading collection data...