You can access the columns of a data frame in R using the column name or the column index.
Example code:
# Access a column by name
name_column <- df$Name
# Access a column by index
age_column <- df[, 2]
# Print the columns
print(name_column)
print(age_column)