online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
#include <iostream> #include <string> #include <array> using namespace std; const int g_iSocketsetup_rows = 7; // Define number of rows in the array = max number of iSockets = 8 units by default = 0 - 7 rows const int g_iSocketsetup_columns = 5; // Define length of the row struct eepromObj { int ssid_flag; // eepromObj of ssid flag confirming ssid is set, "0"- flag is not set, "1" flag is set char ssid[32]; // eepromObj of ssid is 32 chars max. int pass_flag; // eepromObj of pass flag confirming that pass is set, "0"- flag is not set, "1" flag is set char pass[63]; // eepromObj of passphrase is 8 chars min, 63 chars max. char auth[32]; // eepromObj of auth token for blynk int auth_flag; // eepromObj of auth token flag int iSocket_ACK_1_State_Last; // eepromObj of ACK signal state variable int RelayState_Last; // eepromObj of Relay state var - actually is not used but stored for test purposes std::array <std::array <string, g_iSocketsetup_rows>, g_iSocketsetup_columns> iSocketsetup_array{}; // eepromData.iSocketsetup_array[0-7][1-5]: iSocketNo, AddrMCP23017, AddrLM75ADP, AddrMCP3421, RCS_State_last, ACK_State_last } eepromData; // Variable object to read/write to/from EEPROM int main() { int arr_indx_rowNo = 0; int arr_indx_clmnNo = 0; eepromData.iSocketsetup_array[arr_indx_rowNo][arr_indx_clmnNo] = std::to_string(arr_indx_rowNo); cout << eepromData.iSocketsetup_array[arr_indx_rowNo][arr_indx_clmnNo] << endl; return 0; }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue