Insomnia cure

题意翻译

## 题目描述 我们的公主殿下睡不着了!!!于是乎,她就数龙。她之所以数龙,是因为她在九岁时就不想数羊了。 (关于西方睡不着觉就数羊,是因为他们是这样数的:“One sheep!Two sheep!...”而sheep发音与sleep差不多,所以数着数着就变成“One sleep!Two sleep!...了) 然后,公主殿下也不想数龙了,她就想着法子愉悦身心。今天晚上,她就幻想所有的龙都来抢她,然后她就把它们全都给锤了。每第k条龙被她用煎锅在脸上来了几下,每第l条龙的尾巴被阳台门夹了,每第m条龙的爪子被公主穿着高跟鞋猛踩,每第n条龙被公主威胁打电话给家人,让受害者家属惊慌失措。 一共d条龙来抢公主,现在求有多少龙受到物理或精神上的伤害? ## 输入输出格式 ##### 输入格式 输入k,l,m,n,d,一行一个,范围请自己查看。(太懒) ##### 输出格式 输出被公主毁了一生的龙的数量。 ## 说明 第一组样例中,所有龙惨遭厄运。 第二组样例中,第1,7,11,13,17,19,23条龙没有被公主实行非人道手段。

题目描述

«One dragon. Two dragon. Three dragon», — the princess was counting. She had trouble falling asleep, and she got bored of counting lambs when she was nine. However, just counting dragons was boring as well, so she entertained herself at best she could. Tonight she imagined that all dragons were here to steal her, and she was fighting them off. Every $ k $ -th dragon got punched in the face with a frying pan. Every $ l $ -th dragon got his tail shut into the balcony door. Every $ m $ -th dragon got his paws trampled with sharp heels. Finally, she threatened every $ n $ -th dragon to call her mom, and he withdrew in panic. How many imaginary dragons suffered moral or physical damage tonight, if the princess counted a total of $ d $ dragons?

输入输出格式

输入格式


Input data contains integer numbers $ k,l,m,n $ and $ d $ , each number in a separate line ( $ 1<=k,l,m,n<=10 $ , $ 1<=d<=10^{5} $ ).

输出格式


Output the number of damaged dragons.

输入输出样例

输入样例 #1

1
2
3
4
12

输出样例 #1

12

输入样例 #2

2
3
4
5
24

输出样例 #2

17

说明

In the first case every first dragon got punched with a frying pan. Some of the dragons suffered from other reasons as well, but the pan alone would be enough. In the second case dragons 1, 7, 11, 13, 17, 19 and 23 escaped unharmed.