clear; clc; close all;

s = 260;
X = 250;
r = 0.1;
v = 0.3;
T = 1;

N = 252;
dt = T / N;
M = 100000;

c = 0;
for i = 1 : M    
    ds = (1 + r * dt + v * sqrt(dt) * randn(1, N));
    S = s * cumprod([1, ds]);
    p = S(end);
    if p > X
        c = c + p - X;
    end
end
c = c / M * exp(-r * T)
blsprice(s, X, r, T, v)

