From b880a2ba788e1db73ffa994049e7187eaa1436be Mon Sep 17 00:00:00 2001 From: Alexander Popov Date: Tue, 19 Sep 2023 02:28:04 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=20=D1=82=D0=B8=D0=BF=20bool?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- snipplets/code/Arduino/variables_sizes.ino | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/snipplets/code/Arduino/variables_sizes.ino b/snipplets/code/Arduino/variables_sizes.ino index ccf82e4..7bc66e1 100644 --- a/snipplets/code/Arduino/variables_sizes.ino +++ b/snipplets/code/Arduino/variables_sizes.ino @@ -15,6 +15,7 @@ void setup() { double example_double; char example_char; char * example_string; + bool example_bool; size_variable = sizeof(example_int); Serial.print("int bytes size: " ); @@ -47,6 +48,10 @@ void setup() { size_variable = sizeof(example_string); Serial.print("char * bytes size: " ); Serial.println(size_variable); + + size_variable = sizeof(example_bool); + Serial.print("bool bytes size: " ); + Serial.println(size_variable); } void loop() { @@ -64,4 +69,5 @@ void loop() { * double bytes size: 4 * char bytes size: 1 * char * bytes size: 2 + * bool bytes size: 1 */