Hi All,
I have one question for you help me.
I have one string as below:
string str="7+9*6-5";
how we can calculate it?
if you know please do it and send code to me.
Thank advance!
From: Mala
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
JurePosted Oct 1, 2010, 11:41 AM
The string.Split method unfortunately doesn't support splitting and keeping separator strings, so I've wrote StringSplitter class few days ago, which supports various ways of splitting and extracting. Simply add Fresh.dll to your project references to use my library.
Manath PathanaPosted Oct 1, 2010, 6:44 AM
it is string.
but we want to calculate it.
we need to convert:
how to convert operator from string?
and how to convert string to number?
understand my question?
Suthish NairPosted Oct 1, 2010, 6:41 AM
How will this work, read on the query he posted..
Manath PathanaPosted Oct 1, 2010, 6:39 AM
Mean we input string from keyboard as below:
str=7+9*6-5;
then we want to calculate it.
How can we do?
Gomathi PalaniswamyPosted Oct 1, 2010, 6:11 AM
You can calculate like
string str = (7+9*6-5).ToString();