unittest
{
	assert( [ "3", "7 1", "2", "5", "10" ].parse.expand.solve == 8 );
	assert( [ "2", "8 20", "1", "10" ].parse.expand.solve == 29 );
	assert( [ "5", "30 44", "26", "18", "81", "18", "6" ].parse.expand.solve == 56 );
}



import std.algorithm;
import std.conv;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

void main()
{
	stdin.byLineCopy.parse.expand.solve.writeln;
}

auto parse( Range )( Range input )
if( isInputRange!Range && is( ElementType!Range == string ) )
{
	auto n = input.front.strip.to!( long );
	input.popFront;
	auto dx = input.front.split.to!( long[] );
	auto as = new long[ n ];
	foreach( ref a; as )
	{
		input.popFront;
		a = input.front.strip.to!( long );
	}
	return tuple( dx[ 0 ], dx[ 1 ], as );
}

auto solve( long d, long x, long[] as )
{
	auto c = 0L;
	
	foreach( a; as )
	{
		for( auto i = 1; i <= d; i += a )
		{
			c++;
		}
	}
	c += x;
	
	return c;
}
