Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 238 results for
evaluator
- Page 1
Expression Evaluator using Recursion help
Programming
Software Development
14 Years Ago
by Dragosike
… provide a step-by-step process to create an expression
evaluator
in Java using StringTokenizer, Stacks, and Recursion? It would be…. The method I need help with is "public float
evaluator
()" Here's the current code: [CODE] import structures.Stack…
C++ & embedded Python , Expression Evaluator
Programming
Software Development
15 Years Ago
by somada141
… use Python's capabilities in order to create a expression
evaluator
" In more detail: "I will have a custom…
Re: C++ & embedded Python , Expression Evaluator
Programming
Software Development
15 Years Ago
by somada141
… in C++ in order to use it as an expression
evaluator
: First of all the prerequisites: 1)You need to link…
Postfix Evaluator, Java
Programming
Software Development
15 Years Ago
by fcr7
I am trying to create a postfix
evaluator
that uses my IntStack and IntNode class. I cannot figure …
How to Create an Expression Evaluator in C++
Programming
Software Development
15 Years Ago
by arithehun
I am trying to create an expression
evaluator
to expand my C++ knowledge. It is supposed to evaluate …
Re: How to Create an Expression Evaluator in C++
Programming
Software Development
15 Years Ago
by Fbody
[QUOTE=arithehun;1122152]I am trying to create an expression
evaluator
to expand my C++ knowledge. It is supposed to evaluate …
Wesite evaluator
Community Center
14 Years Ago
by dogma7
I had found a website
evaluator
alot like cube stat but it was so much better. …
Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
Hand
evaluator
for Texas Hold'em. If a "hand" has …
automated code evaluator
Programming
Software Development
12 Years Ago
by javalover
Hi friends, I want to create an auto-
evaluator
for java.. If I submit java program, it has to run and show the output or exceptions(if so).. I tried in some simple ways, it doesnt works out. please give some suggestions how to start and progress... Thanks in advance...
PostFix Evaluator
Programming
Software Development
11 Years Ago
by bigredaltoid
… == '*' || c2 == '/')) return true; return false; } } and here is my postfix
evaluator
class import java.util.Stack; public class PostfixEval{ public static…
Re: PostFix Evaluator
Programming
Software Development
11 Years Ago
by JamesCherrill
… them just like numbers when converting to postfix. In the
evaluator
, when you get an variable replace it with its numeric…
Re: PostFix Evaluator
Programming
Software Development
11 Years Ago
by bigredaltoid
I'm a little confused. Would I do that within the
evaluator
method itself? The variable names and values are fixed, I just can't figure out the logic behind the code.
Math Parser and Evaluator Programming Overview Tutorial
Programming
Software Development
11 Years Ago
by xrjf
Have you ever wanted to develop a math parser and
evaluator
? Are you in such a quandary or just have curiosity …
Re: Math Parser and Evaluator Programming Overview Tutorial
Programming
Software Development
11 Years Ago
by Reverend Jim
…;Have you ever wanted to develop a math parser and
evaluator
? At best what you have provided is a black box…
Re: Mathematical Expression Evaluator
Programming
Software Development
12 Years Ago
by bguild
…but I hope the idea is clear. import java.util.*; /**
Evaluator
for expressions of type V */ public final class ExpEval<…} }}; public static void main(String... args) { ExpEval<Integer>
evaluator
= new ExpEval<Integer>(Arrays.asList(intCalculatorOps)); String input…
Re: C++ & embedded Python , Expression Evaluator
Programming
Software Development
15 Years Ago
by Gribouillis
To convert C arrays to numpy, you need to use numpy's C api. This is explained in numpy's documentation. There are a few functions to create a numpy array. The starting point is here [url]http://numpy.scipy.org/#docs[/url].
Re: C++ & embedded Python , Expression Evaluator
Programming
Software Development
15 Years Ago
by somada141
Could you possibly direct me to any simple examples or sth? The numpy API documentation is pretty intimidating
Re: C++ & embedded Python , Expression Evaluator
Programming
Software Development
15 Years Ago
by Gribouillis
I can't help you much, because I never created a numpy array from C, but look at the collection of array creation functions at page 241... of the guide to numpy, and select the most appropriate for your needs :)
Re: How to Create an Expression Evaluator in C++
Programming
Software Development
15 Years Ago
by VilePlecenta
[CODE]#include <iostream> using namespace std; int main() { int x = 0, Total = 0; /* You must make a varaible a, b, c to hold the value unless they are constant */ printf( "Hello. This program will evaluate the expression 5(x+7)-2. \nEnter the value for x: " ); cin >> x; /* Take in the number before…
Re: How to Create an Expression Evaluator in C++
Programming
Software Development
15 Years Ago
by arithehun
[QUOTE=VilePlecenta;1122163][CODE]#include <iostream> using namespace std; int main() { int x = 0, Total = 0; /* You must make a varaible a, b, c to hold the value unless they are constant */ printf( "Hello. This program will evaluate the expression 5(x+7)-2. \nEnter the value for x: " ); cin >…
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by TrustyTony
Even after fixing the docstrings, could not get it to do other than generate one Deck, slicing did not work but dealing with Standard.Deck().popleft() in list comprehension got me some cards from deck.
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
The structure is admittedly confusing. I need to work on that. I had a Dealer class I forgot to include. Some code for shuffling and dealing from the deck because a deck doesn't really shuffle or deal itself. Was a poor decision that sacrificed practicality for purity. Would be easier if they were methods on the deck. How are the docstrings …
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by TrustyTony
docstring from line 175 until 186 for example
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by TrustyTony
Have you considered splitting code to modules? Just using [icode]return self.attr <cond> other.attr[/icode] would compact the helper class quite a bit. On the other hand I do not like the _ variable. It should be also possible to evaluate objects repr to recreate the object.
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
I refactored the code and added an example. The only problem remaining as far as I know is that if two hands are of equal rank but one has higher kickers, my test code will display text suggesting that they are equal. (Differences in kickers are significant in this program though. If one hand has higher kickers than another it will be greater …
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
[code=Python]# -*- coding: utf-8 -*- ##Copyright © 2010 Larry Haskins ##This program is free software: you can redistribute it and/or modify ##it under the terms of the GNU General Public License as published by ##the Free Software Foundation, either version 3 of the License, or ##(at your option) any later version. ##This program is …
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
There is a small bug in my code. The __eq__ method for the card should be: [code=Python]def __eq__(self, other): return hash(self) == hash(other)[/code] I know suits aren't an issue when you compare two cards in a standard game of poker, but if you want to use deck.remove to remove a card you need this new method. Don't worry. It doesn't …
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by TrustyTony
Well done, unit test, cleaner code etc. Some places I would have written little differently, but this is much better than the function test jungle you had before! I would like to mention that this code needs Python 3 to run.
Re: Hold'em Hand Evaluator
Programming
Software Development
14 Years Ago
by lrh9
Yes. I'm coding in Python 3. If you want to propose changes, feel free. You won't be stepping on any toes. I've been collaborating with people on #python on irc.freenode.net. They've given advice and recommendations. Some I've adopted and some I've rejected. Posting the source in this thread was a mistake. I won't make it again. I've had to split…
Re: Hold'em Hand Evaluator
Programming
Software Development
13 Years Ago
by lrh9
Long time no update. I've been studying finite state machines and it has me thinking that some of this might be better solved using finite state machines. The basic idea is that you have a collection of cards you want to find a hand for. You can iterate over the cards and update the state of the hand as you go. When you get to the end of the …
1
2
3
4
Next
Last
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC