Hi @AJS1
libname out "s:/workshop/output";
In this statement, you create a SAS library called 'OUT' which refers to the physical path "s:/workshop/output'.
By default, SAS stores your datasets in a library called 'WORK', but these datasets are available only during the SAS session.
If you want to store a dataset permanently, you need to create permanent libraries (like in your example). This a kind of 'nickname' assigned to a physical folder.
-> s:/workshop/output/class_copy2.sas7bdat will be called out.class_copy2
data class_copy1 out.class_copy2;
set sashelp.class;
run;
In this data step (which begins with DATA and finishes with RUN;), you specify in the first statement the name of the dataset to be created: in your example, you create class_copy1 which is to be stored in the WORK library (you can omit to mention work as it is the default library -> so work.class_copy1 is equal to class_copy1). You create also class_copy2, which is to be stored permanently in the OUT library -> so you will be able to see it in the 's:/workshop/output' folder.
These two datasets are created from the input dataset CLASS, which is stored in the library SASHELP.
This action is done through the SET statement.
SAS provides a lot of materials (books, etc.) to get more familiar with SAS and deeply understand how it works.
You can for example take the free e-learning course SAS Programming 1 available here -> https://support.sas.com/edu/schedules.html?crs=PROG1&ctry=us
The following book is also a great resource: https://www.sas.com/store/books/categories/certification-guide/sas-certified-specialist-prep-guide-b...
And also the SAS community