# Cloze Deletion doesnt function in Code Cards because of curly brackets

**URL:** <https://forums.ankiweb.net/t/cloze-deletion-doesnt-function-in-code-cards-because-of-curly-brackets/17686>\
**Category:** Help\
**Created:** [February 18, 2022, 11:52pm UTC](https://forums.ankiweb.net/t/cloze-deletion-doesnt-function-in-code-cards-because-of-curly-brackets/17686 "2022-02-18T23:52:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![calmar](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/calmar/32/8442_2.png) [@calmar](https://forums.ankiweb.net/u/calmar)\
**Post date:** [February 18, 2022, 11:52pm UTC](https://forums.ankiweb.net/t/cloze-deletion-doesnt-function-in-code-cards-because-of-curly-brackets/17686/1 "2022-02-18T23:52:07Z")

</div>

I am using Obsidian to Anki to create my Anki Cards this is why the screenshot looks a bit different.

It seems like the syntax of the cloze deletion “{{c1:text you don want to see}}” is not compatible in code cards with curly brackets . As you can see in the second screenshot the cloze1 is not found. I troubleshooted it and it seems like the other curly brackets in the codecard are the problem.

Did anyone else here had the problem?

Is it possible to **change the syntax** of the **cloze deletion** to something which doesnt use curly brackets?

Would be nice if someone could show me how to handle this problem :).

 ![image](https://us1.discourse-cdn.com/flex002/uploads/anki2/original/2X/2/2f89f9c9ce32fc985d94cef7e7faaba36665b570.png)

 ![image](https://us1.discourse-cdn.com/flex002/uploads/anki2/original/2X/4/411d7712287bb080baad660d60dfaa161f53391d.png)

EDIT:  
Seems to be a common problem ([https://www.reddit.com/r/Anki/comments/n2gu8x/how\_to\_clozedelete\_mathjax\_formulas\_containing\_and/](https://www.reddit.com/r/Anki/comments/n2gu8x/how_to_clozedelete_mathjax_formulas_containing_and/)) - in this reddit post the answer was just to use **spaces in front and behind** the other curly brackets so that they are not recognized as cloze deletion.

But this is not a solution in my case, because I dont want to manipulate my code using spaces… So the question is still if there is an option to change the Syntax of the Cloze Deletion.

---

<div class="post-metadata">

**Author:** ![BlackBeans](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/blackbeans/32/2283_2.png) [@BlackBeans](https://forums.ankiweb.net/u/BlackBeans)\
**Post date:** [February 19, 2022, 1:23pm UTC](https://forums.ankiweb.net/t/cloze-deletion-doesnt-function-in-code-cards-because-of-curly-brackets/17686/2 "2022-02-19T13:23:48Z")

</div>

Reading your post is hard, due to the number of unmatched delimiters 😛  
Jokes apart, you should try [this add-on](https://ankiweb.net/shared/info/1933645497). The screenshot seems exactly what you are looking for, and you will notice on of the cloze deletion has no spaces around.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/anki2/original/1X/8f1279ababc5879d54e4838989f606cfe55af8c7.jpeg) [@system](https://forums.ankiweb.net/u/system)\
**Post date:** [May 1, 2023, 4:31am UTC](https://forums.ankiweb.net/t/cloze-deletion-doesnt-function-in-code-cards-because-of-curly-brackets/17686/3 "2023-05-01T04:31:20Z")

</div>

Closed on May 1, 2023, 4:31am UTC


