1. Look for patterns - it usually is the case that languages use a particular pattern in their command/syntax structure.
2. Remember the reverse - instead of mapping commands to actions, choose one program you know uses some of them and reverse map actions to commands/syntax. You may forget the syntax, but you probably won't forget problem statements of programs.
3. Think of alternatives. When you have alternative methods in your memory, it's easier to recollect the actual syntax.
4. Practice. There's no better teacher than practice. You go out of touch from one language, you'll actually forget the syntax.
The trick to remember is to find alternative channels that'll aid you to remember; channels that you're sure not to forget.