copying beth's code to my own repo