terça-feira, 13 de outubro de 2020

Container List - declarando e inicializando ( Array de Inteiros )

 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx


//---------------------------------------------------------------------------
//Inicializando com array de inteiros inicializado
#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Alarm clock";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 173, 255, 47 ) );
Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 100;
Label1 -> Top = 35;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 32, 178, 170 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 165, 42, 42 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );

   String str_1;
   String str_2;

  int Vet [ ] = {  0,  1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ,
  11, 12, 13, 14, 15, 16, 17, 18, 19, 20 ,
  21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ,
  31, 32, 33, 34, 35, 36, 37, 38, 39, 40 ,
  41, 42, 43, 44, 45, 46, 47, 48, 49, 50 ,
  51, 52, 53, 54, 55, 56, 57, 58, 59, 60 ,
  61, 62, 63, 64, 65, 66, 67, 68, 69, 70 ,
  71, 72, 73, 74, 75, 76, 77, 78, 79, 80 ,
  81, 82, 83, 84, 85, 86, 87, 88, 89, 90 ,
  91, 92, 93, 94, 95, 96, 97, 98, 99   };

std::list < int > lst ( Vet, Vet + 100 );

for ( int val : lst ) {
str_1 += " ";
if ( val % 10 == 0 )
str_1 += ( "\n" );
if ( val >= 0 && val < 10 )
str_1 += ( "0" );
str_1 += val;
}

Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------

Container List - declarando e inicializando ( Inteiros na declaração )

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx


//---------------------------------------------------------------------------
//Inicializando com inteiros
#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Alarm clock";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 0, 255, 192 ) );
Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 100;
Label1 -> Top = 35;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 206, 234, 251 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 165, 42, 42 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );

   String str_1;
   String str_2;

                  std::list < int > lst ({ 0,  1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ,
  11, 12, 13, 14, 15, 16, 17, 18, 19, 20 ,
  21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ,
  31, 32, 33, 34, 35, 36, 37, 38, 39, 40 ,
  41, 42, 43, 44, 45, 46, 47, 48, 49, 50 ,
  51, 52, 53, 54, 55, 56, 57, 58, 59, 60 ,
  61, 62, 63, 64, 65, 66, 67, 68, 69, 70 ,
  71, 72, 73, 74, 75, 76, 77, 78, 79, 80 ,
  81, 82, 83, 84, 85, 86, 87, 88, 89, 90 ,
  91, 92, 93, 94, 95, 96, 97, 98, 99   });

for ( int val : lst ) {
str_1 += " ";
if ( val % 10 == 0 )
str_1 += ( "\n" );
if ( val >= 0 && val < 10 )
str_1 += ( "0" );
str_1 += val;
}

Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------

segunda-feira, 12 de outubro de 2020

Container List - declarando e inicializando ( Array de string do C ++ Builder )

   xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx



//---------------------------------------------------------------------------
//Inicializando com array de String do C++ Builder
#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>
#define lin  12
#define col 43
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Arial";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 128, 128, 0  ) );

Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 150;
Label1 -> Top = 40;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 255, 255, 255 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;
String texto [ ] = {
"  Manaus, terra boa e quente         ",
"  Eu sabia fazer, mas esqueci        ",
"  Janeiro é o primeiro mês do ano    ",
"  Busque a paz e se envolva com ela  ",
"  Nada melhor do que não fazer nada  ",
"  Cada louco com sua mania           ",
"  Amanhã será um novo dia            ",
"  Nada melhor do que não fazer nada  ",
"  Amanhã será um novo dia            ",
"  Duvido que você não goste de C++   "};

std::list < String > lst ( texto, texto + 10 );

for ( String val : lst ) {
   str_1 += "\n";
   str_1 += val;
}
Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------


Container List - declarando e inicializando ( Array bidimensional de string do C )

  xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx



//---------------------------------------------------------------------------
//Inicializando com array de char bidimensional do C
#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>
#define lin  12
#define col 43
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Arial";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 128, 128, 0  ) );

Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 150;
Label1 -> Top = 40;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 220, 220, 220 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;
const char *texto [ ] = {
"  Manaus, terra boa e quente         ",
"  Eu sabia fazer, mas esqueci        ",
"  Janeiro é o primeiro mês do ano    ",
"  Busque a paz e se envolva com ela  ",
"  Nada melhor do que não fazer nada  ",
"  Cada louco com sua mania           ",
"  Amanhã será um novo dia            ",
"  Nada melhor do que não fazer nada  ",
"  Amanhã será um novo dia            ",
"  Duvido que você não goste de C++   "};

std::list < const char* > lst ( texto, texto + 10 );

for ( const char* val : lst ) {
   str_1 += "\n";
   str_1 += val;
}
Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------



Container List - declarando e inicializando ( Array de char do C )


  xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx



//---------------------------------------------------------------------------
//Inicializando com array de char do C
#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Arial";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 128, 128, 0  ) );

Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 200;
Label1 -> Top = 100;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 224, 255, 255 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;
char A [ 50 ] = {
  ' ', 'B', 'E', 'M', ' ', '-', ' ', 'V', 'I', 'N', 'D', 'O', ' ',
  ' ', 'A', 'O',  '\n', ' ', 'M', 'A', 'R', 'A', 'V', 'I', 'L', 'H', 'O', 'S', 'O', '\n',
  ' ', 'M', 'U', 'N', 'D', 'O', ' ', 'D', 'O', ' ', 'C', '+', '+', ' ', '!' };

std::list < char > lst ( A, A + 50 );

//Converte o array A em set
for ( char val : lst ) {
   str_1 += val;
}
Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------

Container List - declarando e inicializando ( char na declaração )

  xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx





//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
  std::list < char > mst = {
  ' ', 'B', 'E', 'M', ' ', '-', ' ', 'V', 'I', 'N', 'D', 'O', ' ',
  ' ', 'A', 'O',  '\n', ' ', 'M', 'A', 'R', 'A', 'V', 'I', 'L', 'H', 'O', 'S', 'O', '\n',
  ' ', 'M', 'U', 'N', 'D', 'O', ' ', 'D', 'O', ' ', 'C', '+', '+', ' ', '!' };

 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Arial";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 203, 108, 99) );

Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 200;
Label1 -> Top = 100;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 221, 196, 160 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 33, 49, 60 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;

for ( char val : mst ) {
   str_1 += val;
}
Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------

Container List - declarando e inicializando ( Inteiros com push_back )

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx






//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
 std::list < int > lst;

 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Alarm clock";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 222, 208, 202 ) );
Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 100;
Label1 -> Top = 35;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 136, 219, 134 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 33, 49, 60 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;
   String str_2;
   for ( int i = 0; i < 100; i++ )
lst.push_back ( i );

for ( int val : lst ) {
str_1 += " ";
if ( val % 10 == 0 )
str_1 += ( "\n" );
if ( val >= 0 && val < 10 )
str_1 += ( "0" );
str_1 += val;
}

Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------

Container List - declarando e inicializando ( String na declaração )

xxxxxxxxxxxxxxxxxxxxxxxxxxx





//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include <list>

//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
 std::list < String > lst = {
          " ", "00", "01", "02", "03", "04", "05", "06", "07", "08", "09", " ",
"10", "11", "12", "13", "14", "15", "16", "17", "18", "19", " ",
"20", "21", "22", "23", "24", "25", "26", "27", "28", "29", " ",
"30", "31", "32", "33", "34", "35", "36", "37", "38", "39", " ",
"40", "41", "42", "43", "44", "45", "46", "47", "48", "49", " ",
"50", "51", "52", "53", "54", "55", "56", "57", "58", "59", " ",
"60", "61", "62", "63", "64", "65", "66", "67", "68", "69", " ",
"70", "71", "72", "73", "74", "75", "76", "77", "78", "79", " ",
"80", "81", "82", "83", "84", "85", "86", "87", "88", "89", " ",
"90", "91", "92", "93", "94", "95", "96", "97", "98", "99" };

 //---------------------------------------------------------------------------
void __fastcall TForm1::Informe ( TObject *Sender ) {
//SetBkColor ( Canvas -> Handle, RGB ( 255, 182, 193 ) );
Canvas -> Font-> Style = TFontStyles ( ) << fsItalic;
    Canvas -> Font -> Size = 11;
    Canvas -> Font -> Name = "Arial";
Canvas -> Font -> Color = clBlack;
Canvas -> TextOut ( 200, 250, "Por: " );
Canvas -> Font -> Color = clRed;
Canvas -> TextOut ( 240, 250, "Samuel Lima" );
Canvas -> Font -> Color = clBlue;
Canvas -> TextOut ( 200, 265, "sa_sp10@hotmail.com" );
}
 //---------------------------------------------------------------------------
void __fastcall TForm1::Label_Manual ( TObject *Sender ) {
Label1 -> Visible = true;
Label1 -> Font -> Size = 13;
Label1 -> Font -> Name = "Alarm clock";
Label1 -> Font-> Style = TFontStyles ( ) << fsBold;
//Label1 -> Font -> Color = clBlack;
Label1 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
Label1 -> Color = static_cast < TColor > ( RGB ( 231, 220, 203 ) );
Label1 -> Transparent = False;
Label1 -> Width = 100;
Label1 -> Height = 70;
Label1 -> Left = 100;
Label1 -> Top = 35;

/*
Label2 -> Visible = true;
Label2 -> Font -> Size = 13;
Label2 -> Font -> Name = "Arial";
Label2 -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
//Label1 -> Font -> Color = clBlack;
Label2 -> Font -> Color = static_cast < TColor > ( RGB ( 0, 0, 0 ) );
//Label2 -> Color = static_cast < TColor > ( RGB ( 0, 255, 55 ) );
Label2 -> Transparent = False;
Label2 -> Width = 100;
Label2 -> Height = 70;
Label2 -> Left = 350;
Label2 -> Top = 35;
*/
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint ( TObject *Sender ) {
//Alterando a cor do form
Canvas -> Brush -> Color = static_cast < TColor > ( RGB ( 250, 199, 74 ) );
Canvas -> Font -> Size = 14;
Canvas -> Font-> Style = TFontStyles ( ) << fsBold << fsItalic;
Canvas -> Font -> Name = "Arial";
Canvas -> Pen -> Width = 10;
//Colorindo o roundrect com rgb
Canvas -> Pen -> Color = static_cast < TColor > ( RGB ( 116, 21, 10 ) );
Canvas -> RoundRect ( 05, 05, 595, 295, 25, 25 );
//Colorindo a cor de frente do canvas com RGB
SetTextColor ( Canvas -> Handle, RGB ( 255, 0, 0 ) );
//SetBkColor ( Canvas -> Handle, RGB ( 0, 255, 103 ) );
Canvas -> TextOut ( 70, 10, "CONTAINER LIST - DECLARANDO E INICIALIZANDO" );
Informe ( Sender );
   }
//---------------------------------------------------------------------------
void __fastcall TForm1::FormShow ( TObject *Sender ) {
   Label_Manual ( Sender );
   String str_1;
   String str_2;

for ( String val : lst ) {
if ( val == " " )
str_1 += "\n";
str_1 += " ";
str_1 += val;
}

Label1 -> Caption = str_1;
//Label2 -> Caption = str_2;
}
//---------------------------------------------------------------------------