a <- "abc"
b <- "zzz"
list1 <- c(a, seq(1,3))
list1[2]
list2 <- c(b, seq(1,10, by=3))
list2[2:3]
            
list3 <- list2[!is.na(list2)]  
list3[1]
list3[!is.na(list3)]
samples1 <- sample(1:50, replace=TRUE)
class(samples1)
list2 <- c(b, seq(1,10), by=3)
             
#Naming List Elements
# Create a list of a vector, a matrix and a list: 
list_data <- list(c("Jan","Feb","Mar"),
matrix(c(3,9,5,1,-2,8), nrow = 2), list("green",12.3))

# Name the elements of the list:
names(list_data) <- c("1st Quarter", "A_Matrix", "A Inner list")

# display the list: 
print(list_data)

