Let Daniel have x amount of money and Alex have y amount
Given Daniel has rupees160 more than Alex, that is
x=y+160 or
x-y=160.....(1)
Also given after Danial gives giving 1/10 of his money to Alex, he now has 3 times as much money than Alex has. That is
x-x/10=3(y+x/10)
x-0.1x=3y+0.3x
0.6x=3y
x=5y.......(2)
Substitute x = 5y in (1), we get
5y-y=160
4y=160
y=160/4=40
Therefore x=5y=200
Deniel had 200 rupees and Alex had 40 rupees at first.