You are here: Home Software Engineering c++ struct
Search
Advanced Search…
E-Mail

Webmail: webmail.wyden.com

E-Mail Preferences: postfix.wyden.com/users

E-Mail Administration: postfix.wyden.com

Statistics
Total: 473
Total Pages: 286
Total Folders: 87
Total Files: 18
Total Links: 26
Last modification: 19.04.2012 15:21
 

struct

by Wyden Silvan last modified 20.05.2010 14:42

#include<iostream>
#include<string>

using namespace std;

struct produkt {
        int produktnummer;
        int gewicht;
        string produktname;
        bool lager;
    };
   
produkt stuhl;
produkt pult;
int x;

int main ()    {
   
    stuhl.gewicht = 10;
    stuhl.lager = true;
    stuhl.produktname = "Stuhl";
    stuhl.produktnummer = 1234;

    pult.produktname = "Pult";
    pult.gewicht = false;

    cout << "Produktname: " << stuhl.produktname << endl;
    cout << "Produktnummer: " << stuhl.produktnummer << endl;
   
    cin >> x;
   
    }