Object-Oriented Programming in C++

Code display of PL5/aclass3.cpp

// PL5/aclass.cpp
// A populated class for 3 vectors
// Niels Walet, last updated 09/02/2020
#include<iostream>
class vector3
{
private:
  double x{};
  double y{};
  double z{}; 
public:
  // Constructors and destructor
  vector3() = default ;
  vector3(double x_in, double y_in, double z_in) : x{x_in}, y{y_in}, z{z_in} {} 
  ~vector3(){std::cout<<"Destroying vector"<<std::endl;} 











};
Download here; To copy and paste: double click inside code, then copy.