Skip to content

Commit

Permalink
logaritma done
Browse files Browse the repository at this point in the history
  • Loading branch information
rizalfahlevi8 committed May 3, 2024
1 parent 64bbe9f commit 1beb3ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion script.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function operator(value, format) {
operation.value = data.formats.join('');
result.value = data.result;
} else {
if (data.operations.length > 0 && isNaN(parseFloat(data.operations[data.operations.length - 1]))) {
if (data.operations.length > 0 && data.resultformat.length === 0 && isNaN(parseFloat(data.operations[data.operations.length - 1]))) {
data.operations.pop(); // Hapus operator terakhir jika ada
data.formats.pop();
} else {
Expand Down

0 comments on commit 1beb3ed

Please sign in to comment.