Tag: performance

56 votes
12 answers
790 views
Check if a string contains an element from a list (of strings)

For the following block of code: For I = 0 To listOfStrings.Count - 1 If myString.Contains(lstOfStrings.I

avatar
Dorinda
0 1 0 9
asked 07 September, 2021
51 votes
9 answers
2.7K views
Swift Beta performance: sorting arrays

I was implementing an algorithm in Swift Beta and noticed that the performance was very poor. After digging de

avatar
Basil
0 1 0 9
asked 07 September, 2021
55 votes
11 answers
1.4K views
Why is "1000000000000000 in range(1000000000000001)" so fast in Python 3?

It is my understanding that the range() function, which is actually an object type in Python 3, generates its

avatar
Elicia
0 1 0 9
asked 07 September, 2021
66 votes
8 answers
777 views
MySQL vs MongoDB 1000 reads

I have been very excited about MongoDb and have been testing it lately. I had a table called posts in MySQL wi

avatar
Jesenia
0 1 0 9
asked 07 September, 2021
53 votes
7 answers
602 views
When to use CouchDB over MongoDB and vice versa

I am stuck between these two NoSQL databases. In my project I will be creating a database within a database.

avatar
Margo
0 1 0 9
asked 07 September, 2021
63 votes
15 answers
1.4K views
When should I use CROSS APPLY over INNER JOIN?

What is the main purpose of using CROSS APPLY? I have read (vaguely, through posts on the Internet) that cros

avatar
Sena
0 1 0 9
asked 07 September, 2021
57 votes
10 answers
1.9K views
Python Sets vs Lists

In Python, which data structure is more efficient/speedy? Assuming that order is not important to me and I wou

avatar
Trudy
0 1 0 9
asked 07 September, 2021
56 votes
3 answers
1.8K views
Why is printing "B" dramatically slower than printing "#"?

I generated two matrices of 1000 x 1000: First Matrix: O and #. Second Matrix: O and B. Using the following

avatar
Shantay
0 1 0 9
asked 07 September, 2021
63 votes
27 answers
2.9K views
Why is processing a sorted array faster than processing an unsorted array?

Here is a piece of C++ code that shows some very peculiar behavior. For some strange reason, sorting the data

avatar
Boyd
0 1 0 9
asked 07 September, 2021
65 votes
1 answers
2.7K views
Advantages / Disadvantages of pconnect option in CodeIgniter

One of the parameters in the CodeIgniter database config is the following ['pconnect'] TRUE/FALSE

avatar
Janella
0 1 0 9
asked 07 September, 2021
51 votes
25 answers
3.1K views
What is the difference between call and apply?

What is the difference between using call and apply to invoke a function? var func = function() { alert(&ap

avatar
Solomon
0 1 0 9
asked 07 September, 2021
61 votes
30 answers
1.2K views
Which "href" value should I use for JavaScript links, "#" or "javascript:void(0)"?

The following are two methods of building a link that has the sole purpose of running JavaScript code. Which i

avatar
Lynette
0 1 0 9
asked 07 September, 2021