source code for motel applications