The main difference is in the name... One takes place in real time, while the other takes place in turns.
In terms of programming, the difference is that for RTS you will need to be constantly updating/drawing. For TBS, you only need to update when something occurs e.g player hits end turn, so now we calculate the next AI players moves.
Have you played a Total War game? It's pretty obvious how they make use of both systems. The turn-based portion takes place on a large world map, where you move your armies and create castles/cities and the real-time bit is for battles where you fight on a smaller map with 2 or more armies.