# 5 Bit Barker Code

**URL:** <https://discourse.processing.org/t/5-bit-barker-code/31141>\
**Category:** Coding Questions\
**Created:** [July 9, 2021, 4:34pm UTC](https://discourse.processing.org/t/5-bit-barker-code/31141 "2021-07-09T16:34:14Z")\
**Posts on this page:** 1\
**Showing post:** 16

<div class="post-metadata">

**Author:** ![Chrisir](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/chrisir/32/45_2.png) [@Chrisir](https://discourse.processing.org/u/Chrisir)\
**Post date:** [July 12, 2021, 7:38pm UTC](https://discourse.processing.org/t/5-bit-barker-code/31141/16 "2021-07-12T19:38:21Z")

</div>

Here is an example for a Sketch that writes code

It generates for loop, your Sketch B generates code with + etc.

> [@Tools for you: Search file name, Join pde-files and others](https://discourse.processing.org/t/tools-for-you-search-file-name-and-others/10517/8):
>
> Did you ever had to write 9 nested for-loops? for (int i0 = 0; i0 \< 2; i0++) { for (int i1 = 0; i1 \< 2; i1++) { for (int i2 = 0; i2 \< 2; i2++) { .... ...... I wrote another Sketch to write these 9 lines with for-loops for me, so I don’t have to do it. You can copy paste the auto-generated code from the direct window in processing: void setup() { size(800, 600); int numberOfDesiredForLoops = 9; for (int i = 0; i \< numberOfDesiredForLoops; i++) { …

---

_[View the full topic](https://discourse.processing.org/t/5-bit-barker-code/31141)._
