/* package whatever; // don't place package name! */
import java.util.* ;
import java.lang.* ;
import java.io.* ;
import java.math.* ;
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
public static void main
( String [ ] args
) { Scanner sc
= new Scanner
( System .
in ) ; int n = sc.nextInt ( ) ;
int a = sc.nextInt ( ) ;
int b = sc.nextInt ( ) ;
int p = sc.nextInt ( ) ;
int q = sc.nextInt ( ) ;
long ans = 0 ;
int x = n / a;
int y = n / b;
int z = 0 ;
long nr = a * b;
int j = 1 ;
while ( nr <= n && nr > 0 ) {
z++;
j++;
nr = a * b * j;
}
if ( a == b) {
}
else if ( p > q) {
}
else if ( p <= q) {
}
}
}
LyogcGFja2FnZSB3aGF0ZXZlcjsgLy8gZG9uJ3QgcGxhY2UgcGFja2FnZSBuYW1lISAqLwoKaW1wb3J0IGphdmEudXRpbC4qOwppbXBvcnQgamF2YS5sYW5nLio7CmltcG9ydCBqYXZhLmlvLio7CmltcG9ydCBqYXZhLm1hdGguKjsKCi8qIE5hbWUgb2YgdGhlIGNsYXNzIGhhcyB0byBiZSAiTWFpbiIgb25seSBpZiB0aGUgY2xhc3MgaXMgcHVibGljLiAqLwpjbGFzcyBJZGVvbmUKewoJcHVibGljIHN0YXRpYyB2b2lkIG1haW4oU3RyaW5nW10gYXJncykgewoJCVNjYW5uZXIgc2MgPSBuZXcgU2Nhbm5lcihTeXN0ZW0uaW4pOwoJCWludCBuID0gc2MubmV4dEludCgpOwoJCWludCBhID0gc2MubmV4dEludCgpOwoJCWludCBiID0gc2MubmV4dEludCgpOwoJCWludCBwID0gc2MubmV4dEludCgpOwoJCWludCBxID0gc2MubmV4dEludCgpOwoJCQoJCWxvbmcgYW5zID0gMDsKCQkKCQlpbnQgeCA9IG4gLyBhOwoJCWludCB5ID0gbiAvIGI7CgkJaW50IHogPSAwOwoJCQoJCQoJCWxvbmcgbnIgPSBhICogYjsKCQlpbnQgaiA9IDE7CgkJCgkJd2hpbGUgKG5yIDw9IG4gJiYgbnIgPiAwKSB7C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