TAMIKA: Jurnal Tugas Akhir Manajemen Informatika & Komputerisasi Akuntansi
Vol 5 No 2 (2025): TAMIKA: Jurnal Tugas Akhir Manajemen Informatika & Komputerisasi Akuntansi

Perbandingan Kinerja Operator == dan Fungsi Compare() dalam Pemrosesan String pada C++

Fasyih, Muhammad Rofi Nur (Unknown)
Dea Karuniawati (Unknown)
Pasha Ferbitama (Unknown)
Elvina Rizqi (Unknown)
Imam Prayogo Pujiono (Unknown)



Article Info

Publish Date
31 Dec 2025

Abstract

This study compared the performance of the equality operator (==) and the compare() function in C++ for strings. The focus was on their speed and memory efficiency when processing large data sets. Three datasets containing 100, 1,000, and 10,000 random strings ranging in length from 5 to 10 characters were used, each tested three times. Time was measured in microseconds, while memory usage was calculated in kilobytes. The results showed that the compare() function was faster, about 42% faster on the 100-string dataset, and about 9% to 10% faster on larger datasets. Memory usage was similar, differing by only a few hundred bytes. Therefore, use the equality operator (==) for simple comparisons or on small datasets, and use the compare() function for larger data sets. Further research should examine the impact of different compilers, optimization levels, and C++ standard library implementations on these results, as well as include formal statistical analysis of the measured data.

Copyrights © 2025






Journal Info

Abbrev

tamika

Publisher

Subject

Computer Science & IT Decision Sciences, Operations Research & Management Economics, Econometrics & Finance

Description

TAMIKA: Jurnal Tugas Akhir Manajemen Informatika & Komputerisasi Akuntansi merupakan Jurnal Penelitian Bidang Manajemen Informatika dan Komputerisasi Akuntansi yang dikelola ole Program Studi Manajemen Informatika dan Komputerisasi Akuntansi dan diterbitkan oleh Universitas Methodist Indonesia. ...