You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I recently did some serious stress tests on the duck script language, embedded in an application I'm working on.
I may be missing something, but I implemented a standard bubble sort and swap sort in a test script. My results were somewhat surprising.
Test:
Given a text file, containing a pair of numbers on each line (1000 lines) in the following format "1244 5432", parse the text into two unsorted arrays (left and right), then sort each array.
Result:
Bubble Sort... 22s
Left - Sorted in 11s
Right - Sorted in 11s
Swap Sort... 12s 30ms
Left - Sorted in 12s
Right - Fn returned after 30ms, returned array unsorted
I didn't think this language would be incredibly performant, but these results were surprising. The manual sort code was pretty lengthy given that there isn't any sort functions in sdk. Can share if it would help.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I recently did some serious stress tests on the duck script language, embedded in an application I'm working on.
I may be missing something, but I implemented a standard bubble sort and swap sort in a test script. My results were somewhat surprising.
Test:
Given a text file, containing a pair of numbers on each line (1000 lines) in the following format "1244 5432", parse the text into two unsorted arrays (left and right), then sort each array.
Result:
Bubble Sort... 22s
Left - Sorted in 11s
Right - Sorted in 11s
Swap Sort... 12s 30ms
Left - Sorted in 12s
Right - Fn returned after 30ms, returned array unsorted
I didn't think this language would be incredibly performant, but these results were surprising. The manual sort code was pretty lengthy given that there isn't any sort functions in sdk. Can share if it would help.
Beta Was this translation helpful? Give feedback.
All reactions