Using sprintf

Added sprintf to the following files:

- distributed-server.js
- exercises.js
- search_autocomplete.js
- updates.js