I am writing a very simple math game. What I would like to be able to do is this:
Dim symbol as String
Private Sub Math()
symbol = "+"
1 symbol 1 = 2
symbol = "-"
1 symbol 1 = 0
end sub
I know this won't work, but it is the idea I want, thanks in advance.
Func<int,int,int>suffices; i.e.Func<int,int,int> op = (x,y)=>x+y; var sum = op(2,3); // 5(obviously this is C#, but can be translated to VB)