EUVIMEDEUVIMED entdecken
Open Access · CC BY 4.0

Translation of Natural Language to Source Code in the Case of Repetition in Pascal Language

Adi Yusuf, Aditya Kusuma Setyanegara, Muhammad Raafi Febrian Tara

Journal of Creativity, Media, and Communication Studies · 23.04.2025 · 1 (2) · 97-109

DOI: 10.66324/jcmcs.v1i2.112 ↗

Kurz gefasst

Fachartikel in der Zeitschrift Journal of Creativity, Media, and Communication Studies, online erschienen am 23.04.2025. Verfasst von Adi Yusuf und 2 weiteren Autor:innen. Der Volltext ist frei zugänglich (Open Access, CC BY 4.0).

AbstractBibliografische AngabenZitierenVerwandte Studien

Abstract (Originalsprache)

Source code in computer science is a set of commands used to solve problems written in languages that can be understood by computers. Programming languages use concise syntax, and due to this conciseness, they avoid redundancy and ambiguity. However, these languages are often difficult to learn because they require strict adherence to specific syntactic rules. One approach to minimize the difficulty for programmers is to allow program writing using natural language, which is more flexible and easier for humans to understand. Therefore, this research aims to translate natural language, specifically Indonesian, into Pascal source code. The method applied is a rule-based method consisting of three stages: preprocessing (case folding and filtering), analysis (scanning and parsing), and translation. The preprocessing stage removes noise, the analysis stage checks conformity with the defined grammar, and the translation stage converts Indonesian commands into Pascal syntax. Testing was conducted using 60 Indonesian command texts across three types of loop structures (for do, while do, and repeat until). The system achieved an accuracy of approximately 95%. The results show that the rule-based approach is effective in translating repetitive structures. However, improvements to the grammar and parsing rules are recommended to address translation errors and further enhance system accuracy.

Zitieren

APA

Yusuf, A., Setyanegara, A. K., & Tara, M. R. F. (2025). Translation of Natural Language to Source Code in the Case of Repetition in Pascal Language. Journal of Creativity, Media, and Communication Studies, 1(2), 97-109. https://doi.org/10.66324/jcmcs.v1i2.112

Vancouver

Yusuf A, Setyanegara AK, Tara MRF. Translation of Natural Language to Source Code in the Case of Repetition in Pascal Language. Journal of Creativity, Media, and Communication Studies. 2025;1(2):97-109. doi:10.66324/jcmcs.v1i2.112

BibTeX
@article{Yusuf2025,
  author = {Yusuf, Adi and Setyanegara, Aditya Kusuma and Tara, Muhammad Raafi Febrian},
  title = {Translation of Natural Language to Source Code in the Case of Repetition in Pascal Language},
  journal = {Journal of Creativity, Media, and Communication Studies},
  year = {2025},
  volume = {1},
  number = {2},
  pages = {97--109},
  doi = {10.66324/jcmcs.v1i2.112}
}
Kostenlos starten →