Assessing ChatGPT's Code Generation Capabilities with Short vs Long Context Programming Problems

dc.contributor.authorShuvo, Uddip Acharjeeen
dc.contributor.authorDip, Sajib Acharjeeen
dc.contributor.authorVaskar, Nirvar Royen
dc.contributor.authorAl Islam, A. B. M. Alimen
dc.date.accessioned2025-02-06T18:35:39Zen
dc.date.available2025-02-06T18:35:39Zen
dc.date.issued2024-12-19en
dc.date.updated2025-02-01T09:07:07Zen
dc.description.abstractThis study assesses the code generation capabilities of ChatGPT using competitive programming problems from platforms such as LeetCode, HackerRank, and UVa Online Judge. In a novel approach, we contrast ChatGPT’s performance on concise problems from LeetCode against more complex, narrative-driven problems from Codeforces. Our results reveal significant challenges in addressing the intricate narrative structures of Codeforces, with difficulties in problem recognition and strategic planning in extended contexts. While initial code accuracy for LeetCode problems stands at 72%, it drops to 31% for complex Codeforces problems using Python. Additionally, we explore the impact of targeted instructions aimed at enhancing performance, which increased LeetCode accuracy to 73.53% but saw a decrease in Codeforces performance to 29%. Our analysis further extends across multiple programming languages, examining if iterative prompting and specific feedback can enhance code precision and efficiency. We also delve into ChatGPT’s performance on challenging problems and those released post its training period. This research provides insights into the strengths and weaknesses of AI in code generation and lays groundwork for future developments in AI-driven coding tools.en
dc.description.versionPublished versionen
dc.format.mimetypeapplication/pdfen
dc.identifier.doihttps://doi.org/10.1145/3704522.3704535en
dc.identifier.urihttps://hdl.handle.net/10919/124515en
dc.language.isoenen
dc.publisherACMen
dc.rightsCreative Commons Attribution 4.0 Internationalen
dc.rights.holderThe author(s)en
dc.rights.urihttp://creativecommons.org/licenses/by/4.0/en
dc.titleAssessing ChatGPT's Code Generation Capabilities with Short vs Long Context Programming Problemsen
dc.typeArticle - Refereeden
dc.type.dcmitypeTexten

Files

Original bundle
Now showing 1 - 1 of 1
Loading...
Thumbnail Image
Name:
3704522.3704535.pdf
Size:
1.36 MB
Format:
Adobe Portable Document Format
Description:
Published version
License bundle
Now showing 1 - 1 of 1
Name:
license.txt
Size:
1.5 KB
Format:
Item-specific license agreed upon to submission
Description: