index 0=44
index 1=3
index 2=2
index 3=+
index 4=8
index 5=*
index 6 =+
Type: Posts; User: sigur47
index 0=44
index 1=3
index 2=2
index 3=+
index 4=8
index 5=*
index 6 =+
I am working on a code trying to tokenize a string based on white spaces.I have discovered that when ever i try to copy a char from my untokenised string to my string index array it does not copy.
...
When ver i insert an item in evaluate expressionss,It pushes the item onto the stack But the second time it attempts to push onto the stack,Its not able to do so
Can anyone please help me
Can anyone please help suggest something
Thanks typo error.Can you spot anything logically wrong in my evaluate expressions method.
I am writing a program to read a bunch of text and perform boolean operations on it and outputting the result. e.g "T F && T || !" should output false.I have designed my program ,written a parser to...
I am confused.Does the printing add extra space to the parsed string.
i am writing a tokenizer to parse a string. e.g"T T && F && !".Every character is separated by space.I have set up my tokeniser to return T,T,&,F,&,!.The problem that i have is that its returning a...
I have found the problem
Please can anyone tell me what i am doing wrong
I did change it but it still has errors.It builds fine but fails when i run it
Hi ,I have a method which makes a file by using the argument list as parameters.The only problem i have is that it does not work.
void openfile(struct file *p, const char * filename ){
...
I keep getting run failed when ever i try to print out this character.
char *c;
*c='9';
printf ("%c",*c);
I am working on a project and i am trying to work this out.I have an event that occurs every 16.12356 milliseconds.The problem i have is that i need to use that time to count up to 1 second . so it...
unsigned int hashpjw(const void *key) {
const char *ptr;
unsigned int val;
val=0;
ptr=key;
while (*ptr != '\0') {
unsigned int tmp;
val = (val << 4) + (*ptr); ;i dont understand this
if...
I am currently learning how to use maps and i find a few things confusing
e.g if i have
map<string ,vector<string > value;
1.whats the original size of the map when i declare it
2.does each...
What about this
multimap<vector<string>,string > prefixandsuffix;
What would be the best stl container to use for designing a markov chain
my question is if the format of the complex number is not valid,should i adapt my parser to get the best out of the solution
i am sorry,I do not get what you meant by saying in the bolded part above
What if i have a string like this " 2.1 +4.1i20i".Would i need to check to see if the string is a valid complex number
I am working on a c++ book and currently writing a program to solve complex numbers.The problem i have is that i have to read in a string and tokenize it and parse it to set the real and imaginary...
I am trying to use getline to read in a string but its not working
#include <cstdlib>
#include <iostream>
using namespace std;
/*
Hi i am writting a rational number class which has overloaded operators.I am a bit confused woth the isstream operator because i am not sure how it fits in with my code.I want to be able to read in...