Optimization is the act of improving a method or design. In programming, optimization usually takes the form of increasing the speed of an algorithm, or reducing the resources it requires.
3
votes
1answer
43 views
Optimization of average calculation
I have a list of dictionaries, with keys 'a', 'n', 'o', 'u'.
Is there a way to speed up this calculation, for instance with NumPy? There are tens of thousands of items in the list.
The data is drawn ...
3
votes
1answer
39 views
Python Optimizing/Speeding up the retrieval of values in a large string
I have a string containing around 1 million sets of float/int coords, i.e.:
'5.06433685685, 0.32574574576, 2.3467345584, 1,,,'
They are all in one large string and only the first 3 values are ...
3
votes
1answer
64 views
Review for CSS layout code
I want to get my first CSS layout reviewed.
First of all, the related HTML code is as follows -
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
...
-1
votes
1answer
44 views
Optimizations Help [closed]
How can we improve our Yslow performance grade C to A or B.
Looking for some helpful tips on improving the code on our website at www.wirenine.com - any tips to help improve page load times would be ...
2
votes
1answer
32 views
Simple retrieving sessionId rows from indexed SQL column is slow
I have to select all the rows from a database table containing a defined (long)sessionId where the sessionId row is indexed.
But it is slow, and since the code to access it is really simple, I'm ...
3
votes
1answer
31 views
Bash Script(beginner) - Code Improvement Suggestions
I am writing a simple script to automate my regression testing. I am new to bash scripting and my goal is achieve the most efficient and clean code. I have written a simple function to allow me to ...
2
votes
2answers
40 views
Optimization code for checking if a list contains any element ID of another list
I have the following code:
var sessionsWithError = SessionsFilteredByDate.Where(i => i.TrackerId > 0 && i.StatusId == 0).Select(i => i.SessionId);
var ...
3
votes
1answer
89 views
Need an algorithm to optimize grouping python dictionaries in hierarchical form
Previously I asked a question on how to group dictionaries in a list in a hierarchical structure.
Initially I wanted to group a list of dictionaries that looks like the following, using multiple ...
7
votes
3answers
233 views
Can someone improve this C# code
Its working but I don't think its the best way of doing it. I also changed variable names just to let you know,
string [] columnN = AnotherString.Split(','); //Another String is something ...
0
votes
0answers
20 views
optimized way of checking and assigning a function boolean [closed]
Possible Duplicate:
php ideal way to check function returns true
Which of the following way of checking whether a function returns True or FALSE is best, in terms of efficiency and code ...
6
votes
3answers
264 views
PHP ideal way to check function returns true
Which of the following way of checking whether a function returns TRUE or FALSE is best, in terms of efficiency and code readability?
I was told by a friend that Method B is a good practice, but I ...
2
votes
0answers
35 views
Improving the efficiency of a depth-first search method for searching for all “superpalindromes” whose prime factors are all <=N?
A question was asked over at math.SE (here) about whether or not there are infinitely many superpalindromes. I'm going to rephrase the definition to a more suitable one for coding purposes:
...
1
vote
0answers
38 views
AJAX MaskedEditValidator isValidEmpty property manipulation
thanks for visiting ,
this is my initial question that lead me to modify the behavior of
AJAX MaskedEditValidator - isValidEmpty attribute.
when you try to cancel the interaction with a form , ...
7
votes
3answers
252 views
How to optimize this code to get a instant/better result instead of waiting at least 10 seconds every time?
I have the following code that unfortunately is really slow:
private void FilterSessionByDate()
{
SessionsFilteredByDate =
...
4
votes
1answer
40 views
Code review for a collection manipulation tool in Javascript
As I was working with .NET, I started wondering how I would implement the LINQ methods syntax in Javascript. So here is my first try; is there a more elegant, or more performant, way to write this ...