tuse 22 Junior Poster

That is just the reverse of the aforementioned algorithm.

Explanation- Scan the input string from left to right. Whenever you see an operand, just push it onto a stack. When you encounter an operator, pop two elements and concatenate the operator between the two operands and push it back to the stack. Perform this till the input string is fully parsed. The only element left in the stack (if the postfix expression is valid) will be the required infix expression.

eg- AB+

1. push A to stack
2. push B to stack
3. Next element is '+'. pop two elements, B and A apply the operator (A+B) and push it back to stack
4. Since you have fully examined the input string, the element left in the stack is the required expression.

This is just a very basic explanation, google for a more precise technique

ps- the thread name says 'postfix' but in your post, you have given a prefix string (+AB). In such a case just parse the input dtring from R->L in the algorithm.

Hope this helps

jephthah commented: good answer: accurate, but without solving it for them. +12
tuse 22 Junior Poster

Try this-

Just generate 16 x 40 numbers random numbers using the code. If you want it in the range as said, find the remainder of the generated random numbers on division by 10. Then split this one dimensional array into the matrix you need.
------
Hopefully you will get as you need.

But by no means is this the best way to go. There might (must) be a better way.

------
Are you using this for an online test application?

jamello commented: nice one tuse. thanks +2
tuse 22 Junior Poster

cmd = New OleDbCommand("select * from table1 where MFG='& combobox1.text &' ", con) I guess this should be- cmd = New OleDbCommand("select * from table1 where MFG='" & Me.ComboBox1.SelectedItem & "'" ,con) The code you have at present checks if the value & combobox1.text & is present in the field MFG and hence you are getting no records in your Data Grid View.

Its just that you have not used the concatenation correctly.

Hope it helps!

kavithabhaskar commented: Very helpful! +1
tuse 22 Junior Poster

Ok. I got a really helpful reply from a member. How do I make sure that he gets the 'green' against his name?

nav33n commented: Like this. +7