# More an issue rather a coding question

**URL:** <https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925>\
**Category:** Coding Questions\
**Created:** [April 19, 2020, 9:30am UTC](https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925 "2020-04-19T09:30:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![f42ter](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/f42ter/32/16793_2.png) [@f42ter](https://discourse.processing.org/u/f42ter)\
**Post date:** [April 19, 2020, 9:30am UTC](https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925/1 "2020-04-19T09:30:12Z")

</div>

I start to play with an implementation of brainf\*ck. Works well so far, until it come to more complex bf code, like the mandelbrot.bf.

Issue is, that while printig the result using the print statement sometime some printed characters are  
ignored. See fline 1 and 6 of the result. The \* is the carriage return and part of my debugging.

```auto
AAAAAAAAAAAAAAAABBBBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDEGFFEEEEDDDDDDCCCCCCCCCBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB*
AAAAAAAAAAAAAAABBBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDEEEFGIIGFFEEEDDDDDDDDCCCCCCCCCBBBBBBBBBBBBBBBBBBBBBBBBBB*
AAAAAAAAAAAAABBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDEEEEFFFI KHGGGHGEDDDDDDDDDCCCCCCCCCBBBBBBBBBBBBBBBBBBBBBBB*
AAAAAAAAAAAABBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDEEEEEFFGHIMTKLZOGFEEDDDDDDDDDCCCCCCCCCBBBBBBBBBBBBBBBBBBBBB*
AAAAAAAAAAABBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDEEEEEEFGGHHIKPPKIHGFFEEEDDDDDDDDDCCCCCCCCCCBBBBBBBBBBBBBBBBBB*
AAAAAAAAAABBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDDEEEEEEFFGHIJKS X KHHGFEEEEEDDDDDDDDDCCCCCCCCCBBBBBBBBBBBBBBBB*
AAAAAAAAABBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDDEEEEEEFFGQPUVOTY ZQL[MHFEEEEEEEDDDDDDDCCCCCCCCCCCBBBBBBBBBBBBBB*

```

So the result at the end the lines looks different from time to time, so other lines are affected.  
I have seen this in some of my programs, but the behavior is different, cause while using large number of debug print statements Processing freeze. Interseting enough independent of the last few versions and OS. I have this behaviour on Win 10, and Raspbian on a 3+ and Raspbian x86.

Is there a know limitation recommended for print statements or is this a more complex issue of memory management in the underlying java?. I also increased memory, but no change.

So it is not such an important issue for me, but wants to know if somebody else have similar issues while using print/println heavily.

Stay save and at home.  
f42ter

---

<div class="post-metadata">

**Author:** ![Kevin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kevin/32/2297_2.png) [@Kevin](https://discourse.processing.org/u/Kevin)\
**Post date:** [April 24, 2020, 1:53am UTC](https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925/2 "2020-04-24T01:53:40Z")

</div>

What do you mean when you say the lines look different? Can you give an example of what you expect to print compared to what’s actually printing? Can you post a small example program that shows the problem, so we can run it ourselves to help debug?

---

<div class="post-metadata">

**Author:** ![f42ter](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/f42ter/32/16793_2.png) [@f42ter](https://discourse.processing.org/u/f42ter)\
**Post date:** [April 25, 2020, 7:57am UTC](https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925/3 "2020-04-25T07:57:19Z")

</div>

Thanks for offer your help. Output is correct when using text instead of print in the console.  
It occurs in this particular case only when running mandelbrot.bf in my processing brainf\*ck emulator.  
I’ve seen this behavior in some other of my sketches when using large amounts of println debug statements.

My issue was to understand if my bf interpreter is working properly. Cause many other tests work well. And mandelbrot is a stresstest.

---

<div class="post-metadata">

**Author:** ![jeremydouglass](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jeremydouglass/32/20_2.png) [@jeremydouglass](https://discourse.processing.org/u/jeremydouglass)\
**Post date:** [May 1, 2020, 1:05am UTC](https://discourse.processing.org/t/more-an-issue-rather-a-coding-question/19925/4 "2020-05-01T01:05:27Z")

</div>

> [@f42ter](#):
>
> Output is correct when using text instead of print in the console.

The console ini PDE is intentionally throttled / cropped. That prevents it from having negative performance impacts on everything else. So the console is not a good place to debug very large repetitive text outputs – don’t stress-test print() or println(), it will drop contents by design. Instead, dump those to files – or dump into a variable like a String / StringBuffer, then run tests on the contents (test-driven development).
