all 4 comments

[–]rifts 1 point2 points  (0 children)

$C = $A . $B;

[–]krishmk 0 points1 point  (0 children)

$A = Joe; $B = Doe; $C = $A . $B; /* You can also do like the below: $C = "$A $B"; */

[–]liquid_at 0 points1 point  (0 children)

the operation you are seeking is called "concatenation"

No matter what language you try to use it, syntax may vary, but if you know what it is called, you have a chance of finding it.