Search Results

Search found 4 results on 1 pages for 'nunu'.

Page 1/1 | 1 

  • Haskell Syntax: Parse Error On Input

    - by NuNu
    As part of a mini-haskell compiler that I'm writing, I have a function named app. What I want this function to do is take in these arguments epp (App e1 e2). The first step would be to evaluate e1 recursively (epp e1) and check if the output would be an error. If not then evaluate e2 and then call another function eppVals to evaluate the outputs of the calls on e1 and e2 which I defined as v1 and v2 respectively. epp (App e1 e2) | epp e1 /= Error = eppVals v1 v2 | otherwise = Error where v1 = epp e1 v2 = epp e2 <- parse error on input `=' Logically I believe what I have written so far works but I'm getting a parse error on input = where I stated above. Any idea why? My second try epp :: Exp -> Error Val epp (App e1 e2) = (eppVals v1 v2) where v1 = (epp e1) v2 = (epp e2) But now throws Couldn't match expected type Val with actual type Error Val

    Read the article

  • Store data in file system rather than SQL or Oracle database.

    - by nunu
    Hi All, As I am working on Employee Management system, I have two table (for example) in database as given below. EmployeeMaster (DB table structure) EmployeeID (PK) | EmployeeName | City MonthMaster (DB table structure) Month | Year | EmployeeID (FK) | PrenentDays | BasicSalary Now my question is, I want to store data in file system rather than storing data in SQL or ORACLE. I want my data in file system storage for Insert, Edit and Delete opration with keeping relation with objects too. I am a C# developer, Could anybody have thoughts or idea on it. (To store data in file system with keeping relations between them) Thanks in advance. Any ideas on it?

    Read the article

  • Cartesian Plane

    - by NuNu
    I'm trying to define a function in Haskell that takes an integer argument c and returns the list of all points on the cartesian plane of the form (x/c,y/c) where x and y are integers. x/c is between -2 and 1 and y/r is between -1 and 1 This is what I've gotten so far which I'm almost sure is right but I'm getting a parse error on input = when I run it particularly at this line: cart xs ys c = [(y/c,x/c) | x <- xs, y <- ys] plane :: Int -> [a] plane c = cart [-1*c .. 1*c] [-2*c .. 1*c] c cart xs ys c = [(y/c,x/c) | x <- xs, y <- ys] A sample output would be: plane 1 would generate: [(-2.0, -1.0), (-1.0, -1.0), ( 0.0, -1.0), ( 1.0, -1.0), (-2.0, 0.0), (-1.0, 0.0), ( 0.0, 0.0), ( 1.0, 0.0), (-2.0, 1.0), (-1.0, 1.0), ( 0.0, 1.0), ( 1.0, 1.0)] Anyone have any idea how I can fix this! Thanks

    Read the article

  • PHP array minor problem

    - by Sennheiser
    I'm really not sure how to explain this. It's so simple I can't fathom why it's not working. I have a loop. It puts a bunch of strings into an array. If I fill a single variable with any given string, it will output it perfectly. But filling an array with the strings will make it give me the dreaded: Array Array Array Array Array Array Array Array Note: my strings are not all 'Array'. The way I loop is: while(...) { $arr[] = $resultFromLoop; } Here is my var_dump. array(1) { ["tagName"]=> string(5) "magic" } array(1) { ["tagName"]=> string(4) "nunu" } array(1) { ["tagName"]=> string(5) "books" } array(1) { ["tagName"]=> string(0) "" } array(1) { ["tagName"]=> string(3) "zzz" } array(1) { ["tagName"]=> string(4) "grey" } array(1) { ["tagName"]=> string(3) "new" } array(1) { ["tagName"]=> string(6) "flight" }

    Read the article

1