Programming puzzles: processing lists!
|
05-26-2019, 05:51 PM
(This post was last modified: 05-26-2019 06:52 PM by pier4r.)
Post: #280
|
|||
|
|||
RE: Programming puzzles: processing lists!
For #45 (actually on strings rather than reals but it is the same) I am using this program
Code:
Where gvLBaseWordsColPaper is a list of words with possible duplicates in the form exposed at the end. Obviously since the comparison are being done for each element in the list (therefore O(n^2) ), when the list is long enough, it is going to take long even on emu48 (that it is still simulated). So now I am going to use ksort to speed up the algorithm. Code:
--------- And a bit faster code. Code:
Wikis are great, Contribute :) |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)