comparison

What are the differences between Mono's and Microsoft's ASP.NET implementations?

Hi Everyone, I'm about to launch an ASP.NET web site which will be running on a Linux server using Mono. First I would like to do some testing on my own machine. I have heard lots of info about Mono, but this is the first time I actually use it for a project. So far, I have only deployed my applications on IIS servers. I would like to ...

Why would an IN condition be slower than "=" in sql?

Check the question This SELECT query takes 180 seconds to finish (check the comments on the question itself). The IN get to be compared against only one value, but still the time difference is enormous. Why is it like that? ...

If Lisp is the perfect language, why are there so many?

Possible Duplicate: Why is the Lisp community so fragmented? Despite the snarky tone, I'm actually looking for a serious answer. I know the textbook response: Lisp is a model for computation, not a "language" per se. Still, why exactly are there so many different dialects of Lisp? Presumably it isn't because of surface synt...

Why is Date1.CompareTo(Date2) > 0 faster than Date1 > Date2?

Another "unimportant" performance question. Unimportant because mostly code-readability is much more important than a few milliseconds, but interesting anyway. I noticed that there are differences between different DateTime Comparisons. I checked 3 alternatives: Dim clock As New System.Diagnostics.Stopwatch Dim t1, t2, t3 As Lo...

How to not include line breaks when comparing two strings.

i am comparing updates to two strings. i did a: string1 != string2 and they turn out different. I put them in the "Add Watch" and i see the only difference is one has line breaks and the other doesnt'.: string1 = "This is a test. \nThis is a test"; string2 = "This is a test. This is a test"; i basically want to do a compare bu...

Comparing local file with remote file

Hi, I have the following problem ,I have a local zip file and a zip file located on a server. I need to check if the zip file on the server in different from the local one,if they are not I need to pull the new one from the server.My question is how do I compare them without downloading the file from the server and comparing them locally...

How to manipulate and validate string containing conditions that will be evaluated by php.

Part of the program I am creating consists of the user creating conditions which I will store in a mysql database. I want the syntax to be somewhat easier than what php allows but since this will ultimately be run as php code using eval() it needs to have valid syntax. For example: User Input: 4<var1<=9 AND var2<6 Result should be: ...

Comparing two arrays in Javascript - Returning differences

Assuming we have: array1 = ['A', 'B', 'C', 'D', 'E']; array2 = ['C', 'E']; Is there a proven and fast solution to compare two arrays against each other, returning one array without the values appearing in both arrays (C and E here). So: array3 = ['A', 'B', 'D'] should be the output of the solution. (jquery may be involved) thx. ...

Escaping in test comparisons

In the following, I would like check if a given variable name is set: $ set hello $ echo $1 hello $ echo $hello $ [[ -z \$$1 ]] && echo true || echo false false Since $hello is unset, I would expect the test to return true. What's wrong here? I would assume I am escaping the dollar incorrectly. TYIA ...

Comparing negative numbers in javascript

I'm sure this is a simple problem, but I'm comparing negative numbers in javascript i.e.: var num1 = -83.778; var num2 = -83.356; if(num1 < num2) { // Take action 1 } else { // Take action 2 } This script will always take action 2, even though num1 is less than num2. Whats going on here? ...

Compare two ArrayList Contents using c#

I have two arraylist. Namely ExistingProcess and CurrentProcess. The ExistingProcess arraylist contains the list of process that was running when this application started. The CurrentProcess arraylist is in a thread to fetch the process running in the system all the time. Each time the currentProcess arraylist gets the current process...

Sharepoint Server 2010 or Sharepoint Foundation 2010 for development?

Ok first of all what is the difference between these two products? Secondly are the development skills interchangeable between Server 2010 and Foundation 2010? And lastly in terms of job market, when HR department writes "Looking for Sharepoint developer" do they mean developer for Sharepoint Server (MOSS) or Sharepoint Foundation (Ser...

j2ee versus .net development estimates

This is not a request for opinions. Please only respond if you are 1) a strong j2ee/oracle developer 2) a strong .net/sql server developer, and 3) have developed nontrivial web apps in each framework. My question is what is the relative development time for a given specification in each platform. Let's say for the sake of comparison t...

How does Python stack up to other scripting languages?

I'm learning Python (and it's my first programming language so don't be too intense with your reasons) and I wanted to know how it stacks up to other scripting languages, like Perl and Ruby. What is Python better in comparison to other scripting languages, and what is it worse for? ...

which collection should be used depending on the performance ?

I am developing the asp.net mobile application. I am using xml as a database. In the following xml file I am retriving the all the attributes by using LINQ to xml. In this way there are nearly 10 to 30 attributes. I am adding the values of these attributes dynamically into the Hashtable. In coding part I am using following code...

browser features database

I'm looking for some comprehensive list of web browser compatibility with various versions of standards like javascript, CSS, DOM, HTML.. I know about quirksmode.org, but I'm hoping there are other good resources as well. ...

How to get all the possible values of a function called with any two values of an array?

Consider this code: class MyClass { string PropertyA; int PropertyB; double PropertyC; object PropertyD; static ComparisonResult Compare(MyClass a, MyClass b){ // returns a ComparisonResult with // _sampleElement = a // _commonProperties = flags that describe the common properties of a and b ...

(Deep) comparison of an object to a reference in unit tests (C#)

Hi all, In a Unit Test (in Visual Studio 2008) I want to compare the content of a large object (a list of custom types, to be precise) with a stored reference of this object. The goal is to make sure, that any later refactorings of the code produces the same object content. Discarded Idea: A first thought was to serialize to XML, and t...

Would it break the language or existing code if we'd add safe signed/unsigned compares to C/C++?

After reading this question on signed/unsigned compares (they come up every couple of days I'd say): http://stackoverflow.com/questions/3475841/signed-unsigned-comparison-and-wall I wondered why we don't have proper signed unsigned compares and instead this horrible mess? Take the output from this small program: #include <stdio.h>...

Pattern matching variables in a case statement in Haskell

If I compare a string literal to a string literal using the case statement, I get the expected behavior: if they are the same - it matches, if they are not - it does not. However, if I compare a string literal to a constant that is a string, I get "Pattern matches are overlapped" warning and the branch with the constant always matches. ...