CSClubIIITDM-org / bughunt-2024

Repo for BugHunt vashisht2024
0 stars 35 forks source link

[Code Commandos] c/c++ 7 #182

Open Sahilll94 opened 7 months ago

Sahilll94 commented 7 months ago

b"bZ\x8a\x16d\xbf\t<\x0f\xc3\x04\xbeM%\xc0\x03\x93\x1ajI\x17\x81jg+\xa8p\x0e\x17\xde\xde[\xee$\x88\x87\x07\xcdm\xb4\xce\xd65\xc9\xd1\xfa\x9dg\xe4]\xdc}\t\x9e5\x9eH\x1b\xb4\xebn\x14\xf78d\xbf\xec\xaf~\x14\xbd\xf9\x8ab\xc4\x9e\xa2\x95&yEb\x96\x8c\xf7\xafL\xc9G\xb8\xa9\xeb\xeb8\xce/\xcbLN\xef\xce\xd8Yzi\xeaa\xbd\xc2\xfb\xe3C]\x906O|\x1f'w\xf8y\x1ci\xfc\x95"

b'gAAAAABl9TF_4BxMFeQ46Ds3vVgxiYRvi1bB8BuNctw5els_5A9KV4YLYUEXnMH6YaPVzEKmV3WfqheO5SnalhW74bTdPivKXBwoInDasl9lIUmNQEqb_9YP6WIMY3YcN3ro4gL9J5K7wu5kPrJOFg5bOuFGaaR8FpqRHjEMHgRGxD7DAvHABfcZwNet4TlcaTU3fMx_3WUus8qsWXW7dwdwzQAORJH03jJ8WXWR3KSIYDH760F9EbaMmRa_wW_CFSFdPOPdzJhLH9M1QlJriuZLmCewyDmRA4CA0bpNIiXcPcx8W2BlIqtiTaxTS47dtClBlxxiBO2Ho2pmsTac8ZIt-2DXmY1ETXuRjJRDFlTBLO3PT6tcVIhqTeEA5tUpRRoes7TmECrzCu_3UvV_Jg4ynAbQwiD8ag9N5jP_VlKcT9I0F9Qze7v6ur5VhkWkcgZc5eD-0Q66iFANv8dTAHUZ8uViVKVNBPeB36M9EkiNDko0NMnbosnxK4AcXBFZG9DPSReyRc4eoHA2KfMj5GMW3f7zVxoQf6plCNhR4uB2CpfbnvRi7kU66EAww8pDFn6JQujtdgP986cSgH5o6SA8IkxJYkWoNh_sjtsUgp4ecR82ICmS0dgUPvQ6aANZp27Yzli--oXrF5t7R_CinesrreHK8NrOxuJB1e5Q4JBfDpImYV3zLi9KjTummq9f6dtkHBgMOYQ13sl7jrRvmd1v4UCCouxygg=='

bughunt-bot[bot] commented 7 months ago

Team Name: Code Commandos File Name: c/c++ 7 Line Number: [9] Bug Description: This condition is incorrect because counter is initialized to -1, and then it's incremented before checking against the length of the string s. This means the loop will execute one more iteration than needed, resulting in an incorrect count of the length of the string.

Solution: To fix this, initialize counter to 0, and then increment it within the loop after checking the condition.

bughunt-bot[bot] commented 7 months ago

Bug Hunt Evaluation: Answer: ((9,),) Correctness: 1/1 Points: 100/100