evaluation

Deferred Evaluation of strings in Linq to SQL

I seem to be having a problem when using Linq to Sql in which the Where method adds a string reference to the criteria list. When the reference is changed, it produces erroneous results. For example, the code snippet below when used with the input text 'John Smith' returns all records whose name contains 'Smith' var qry = from c in ct...

C# bool expression evaluation order

Possible Duplicate: == Operator and operands Possible Duplicates: Is there any difference between if(a==5) or if(5==a) in C#? == Operator and operands Ok, this may be stupid question, but searching in google (cant seem to ACTUALLY search for an exact phrase even with quotes) What if any difference is there between i...

Tests for Evaluating an Application Stack or Framework

I'm looking for a set of scenarios that can be used to assess the overall elegance, strengths and weaknesses of a given MVC framework. For instance, one such test could be how cleanly authorization is handled when it affects elements in the presentation layer. If the user has permission to see elements within an object, is that decision...

Tools to evaluate callgrind's call profiles?

Somehow related to this question, which tool would you recommend to evaluate the profiling data created with callgrind? It does not have to have a graphical interface, but it should prepare the results in a concise, clear and easy-to-interpret way. I know about e.g. kcachegrind, but this program is missing some features such as data ex...

Getting code statistics from big projects

I'm interested in code statistics tools. Specifically I need to get statistics on Java EE code, but any code analyzer would do. Should I start creating one of my own or is there some project that you have used? ex. LOC, number of classes , libs ... What is your experience ? ...

Looking for software suite to perform partial evaluation to reduce constants

Hi, We have need in our product to do partial evaluation to simplify expressions that contain both variables and constants. Goal is to combine terms algebraically to reduce the constants whenever possible. For example the following expressions: 4x + 6y + 2x 7 + 2x - 3 10^-5 * x * 10^-4 Should become (respectively): 6(x + y) 4 + 2x...

When evaluating Visual Studio 2010, should you install the Ultimate version, or the version you think your company is most likely to purchase?

I want to install Visual Studio 2010 Beta 2 and I see several versions - seems they've gone a little nuts with the versions this time around so there's "Professional", "Premium" and "Ultimate". When it comes to Visual Studio 2008 we went with the Professional edition. I'm not privy to the reasoning but it serves our needs. On the one h...

How do you evaluate a string as a clojure expression?

How would I get something similar to the following?: (evaluate-text "(+ 1 2)") ; resolves to 3 ...

Partial evaluation with pyparsing

I need to be able to take a formula that uses the OpenDocument formula syntax, parse it into syntax that Python can understand, but without evaluating the variables, and then be able to evaluate the formula many times with changing valuables for the variables. Formulas can be user input, so pyparsing allows me to both effectively handle ...

BODMAS assignment

Hello All, Im working on a problem that goes like this - Implement a function that evaluates an expression consisting of following operands : '(', ')', '+', '-', '*', '/'. Each numbers in the expression could be large (as large as being represented by string of 1000 digits). The '/' (i.e. divide) operand returns the integer quotient. ...

Evaluating developers

I am a technical team leader of a small programming team, working on a project for an external client. I was recently asked to produce written evaluations of my team members. I feel uncomfortable doing this, because I don't see myself as a management person and never thought of my colleagues much deeper than "A is reliable and B is a la...

C++ expression evaluation order

i ran into a curious problem regarding evaluation of expressions: reference operator()(size_type i, size_type j) { return by_index(i, j, index)(i, j); // return matrix index reference with changed i, j } matrix& by_index(size_type &i, size_type &j, index_vector &index) { size_type a = position(i, index); // find position of i using...

Which languages have readily available safe evaluation environments?

I'm speaking specifically of something like the PLT Scheme make-evaluator. It will run scheme code, but under certain conditions: It only uses a definable amount of memory, and will quit execution if the script needs more It behaves similarly with time It restricts all IO except for what I specifically allow in the code Is anyone ...

When evaluating an iPhone dev shop, best questions to ask?

We are currently in the process of evaluating a couple of iPhone development shops and we're putting together a list of questions/topics that we'll be asking them about when we meet. To make sure that we have the most relevant areas covered, what would you ask when evaluating an iPhone developer or development shop? Our main areas are:...

SQL UPDATE order of evaluation

What is the order of evaluation in the following query: UPDATE tbl SET q = q + 1, p = q; That is, will "tbl"."p" be set to q or q + 1? Is order of evaluation here governed by SQL standard? Thanks. UPDATE After considering Migs' answer, I ran some tests on all DBs I could find. While I don't know what the standard says, implementa...

In Java, what are the boolean "order of operations"?

Let's take a simple example of an object "Cat". I want to be sure the "not null" cat is either orange or grey. if(cat != null && cat.getColor() == "orange" || cat.getColor() == "grey") { //do stuff } I believe AND comes first, then the OR. I'm kinda fuzzy though, so here are my questions: 1) Can someone walk me through this state...

tic tac toe using alpha beta prunning in java

Hello, I am trying to play tic tac toe using iterative Alpha-Beta prunning, I have one second limit for a move but for some reason it doesnt work well. I modified the regular alpha-beta code so instead of returning alpha or beta, it returns a state (which is the board with the next move) Each time I create children I update their dept...

Deferred evaluation in python

I have heard of deferred evaluation in python (for example here), is it just referring to how lambdas are evaluated by the interpreter only when they are used? Or is this the proper term for describing how, due to python's dynamic design, it will not catch many errors until runtime? Or am I missing something entirely? ...

Is there a Language Reference Manual for PowerShell?

I'm evaluating Windows PowerShell as a replacement for cmd.exe for basic process automation for command-line code (e.g. setup, execution, and post-processing of large numbers of Fortran jobs.) I know enough perl and shell to achieve what I want but I'm trying to stay within the Windows toolchain rather than needing to train my coworkers ...

Why can't I bind + in clojure?

Can anyone explain why I can rebind list but not +? (binding [list vector] (list 1 3)) (binding [list +] (list 1 3)) (binding [+ list] (+ 1 3)) I'd like to rebind + so I can do partial evaluation. ...