# Trouble adding a second cloze among many in a latex equation

Remark: Don’t be thrown off by the amount of equations, it’s just about where to set the clozing double-braces ("}}") for a second clozing part ( c2::{{ }} ).

So I built cloze cards with multiple clozing parts, which work very well up to a certain point:
this:

Derive the OLS estimate for (\hat{\beta_1})

(\begin{align*} &\Rightarrow \frac{\delta RSS}{{{c1::\delta \beta_1}}} \sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}*x_i)^2 \ &= {{c1::\sum^n_{i=1}2(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(-x_i)}} \ &= {{c1::-2 * \sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &\Rightarrow {{c1::\sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &\rightarrow \hat{\beta_0} = \bar{y} - \hat{\beta_1}\bar{x} \ &= {{c1::\sum^n_{i=1}(y_i - (\bar{y} - \hat{\beta_1}\bar{x}) - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &= {{c1::\sum^n_{i=1}(y_i - \bar{y} + \hat{\beta_1}\bar{x} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &= {{c1::\sum^n_{i=1}(y_i - \bar{y}) (x_i) - \hat{\beta_1} \sum^n_{i=1} (x_i - \bar{x})(x_i)}} &= 0 \ &= \sum^n_{i=1}(y_i - \bar{y}) (x_i) &= {{c1::\hat{\beta_1} \sum^n_{i=1} (x_i - \bar{x})(x_i)}} \ &\Rightarrow \hat{\beta_1} = \frac{\sum^n_{i=1}(y_i - \bar{y}) (x_i)}{\sum^n_{i=1} (x_i - \bar{x})(x_i)} \ &= \frac{\sum^n_{i=1}(y_i - \bar{y}) (x_i - \bar{x})}{\sum^n_{i=1} (x_i - \bar{x})^2} \ &= \frac{Cov(X, Y)}{Var(X)}\end{align})

I wonder however, why when I use another one, it gives me an error and doesn’t properly render the card:

Derive the OLS estimate for (\hat{\beta_1})

(\begin{align*} &\Rightarrow \frac{\delta RSS}{{{c1::\delta \beta_1}}} \sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}*x_i)^2 \ &= {{c1::\sum^n_{i=1}2(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(-x_i)}} \ &= {{c1::-2 * \sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &\Rightarrow {{c1::\sum^n_{i=1}(y_i - \hat{\beta_0} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &\rightarrow \hat{\beta_0} = \bar{y} - \hat{\beta_1}\bar{x} \ &= {{c1::\sum^n_{i=1}(y_i - (\bar{y} - \hat{\beta_1}\bar{x}) - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &= {{c1::\sum^n_{i=1}(y_i - \bar{y} + \hat{\beta_1}\bar{x} - \hat{\beta_1}x_i)(x_i)}} &= 0 \ &= {{c1::\sum^n_{i=1}(y_i - \bar{y}) (x_i) - \hat{\beta_1} \sum^n_{i=1} (x_i - \bar{x})(x_i)}} &= 0 \ &= \sum^n_{i=1}(y_i - \bar{y}) (x_i) &= {{c1::\hat{\beta_1} \sum^n_{i=1} (x_i - \bar{x})(x_i)}} \ &\Rightarrow \hat{\beta_1} = {{c2::\frac{\sum^n_{i=1}(y_i - \bar{y}) (x_i)}{\sum^n_{i=1} (x_i - \bar{x})(x_i)}}} \ &= \frac{\sum^n_{i=1}(y_i - \bar{y}) (x_i - \bar{x})}{\sum^n_{i=1} (x_i - \bar{x})^2} \ &= \frac{Cov(X, Y)}{Var(X)}\end{align})

The c2 closing seems to throw some trouble, what’s the issue?

Edit: Changed formatting.

Thank you!