# For loop verification from remote host

**URL:** <https://forum.ansible.com/t/for-loop-verification-from-remote-host/23937>\
**Category:** Ansible Project\
**Created:** [March 11, 2017, 4:21pm UTC](https://forum.ansible.com/t/for-loop-verification-from-remote-host/23937 "2017-03-11T16:21:33Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Madhu](https://avatars.discourse-cdn.com/v4/letter/m/a8b319/32.png) [@Madhu](https://forum.ansible.com/u/Madhu)\
**Post date:** [March 11, 2017, 4:21pm UTC](https://forum.ansible.com/t/for-loop-verification-from-remote-host/23937/1 "2017-03-11T16:21:33Z")

</div>

Hi,

I want to verify the routes getting from remote host to a local variable. Local variable have the routes in the list. Can you guys please tell me how to do it with an example? Below is my playbook with the local variable storing the routes.

- name: Generate the routes and store in file  
set\_fact:

variable: “[{% for i in range(0,256,16) %}{% for j in range(0,256,1) %}‘120.100.{{ j }}.{{ i }}’,{% endfor %}{% endfor %}]”

- name: Dump the routes  
debug: var=variable

Thanks,  
Madhu
