alt. impl of js ex 01 by C-Medication team