Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
as B1ts said, your code performs out-of-bounds accesses when
strlen(str2) >= 9
, becausei > 0
is then always true as you keep incrementingi
. Please use thequestion
label to ask for help next time.First of all, the error is coming from your code. I have no idea what's happening in your solution, but the part
for(size_t i = (strlen(str2)-1)/8; i > 0; ++i){
is clearly wrong and will lead to invalid memory access errors.You should format your solution next time, because this is unreadable. See https://docs.codewars.com/references/markdown/#code-block