# putting a var inside "template expression" in task

**URL:** <https://forum.ansible.com/t/putting-a-var-inside-template-expression-in-task/22804>\
**Category:** Ansible Project\
**Created:** [October 17, 2016, 9:52am UTC](https://forum.ansible.com/t/putting-a-var-inside-template-expression-in-task/22804 "2016-10-17T09:52:36Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yosef\_Yudilevich](https://avatars.discourse-cdn.com/v4/letter/y/f08c70/32.png) [@Yosef\_Yudilevich](https://forum.ansible.com/u/Yosef_Yudilevich)\
**Post date:** [October 17, 2016, 9:52am UTC](https://forum.ansible.com/t/putting-a-var-inside-template-expression-in-task/22804/1 "2016-10-17T09:52:36Z")

</div>

hi  
i know that the way i put it here it wont work  
but what is the proper way to do it? put {{ COUNT }} variable inside bucket\_ram\_quota: “{{ ( 800 / {{ COUNT }} ) | int }}”

thanks

---

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [October 17, 2016, 6:18pm UTC](https://forum.ansible.com/t/putting-a-var-inside-template-expression-in-task/22804/2 "2016-10-17T18:18:41Z")

</div>

You already have curly brackets, so remove the ones inside.

&nbsp;&nbsp;&nbsp;bucket\_ram\_quota: "{{ ( 800 / COUNT ) | int }}"
