when talking about proteins, secondary structure is structure that comes from hydrogen bonding between oxygens and hydrogens in the generic part of the protein backbone. The peptide bonds linking amino acids are covalent bonds that form when the carboxyl (-(C=O)-O⁻) of one amino acid joins with the amino (NH₂/-NH₃⁺) group of another amino acid. This leaves you with alternating potential H-bond donors (the H on the NH) and acceptors (the O on the C=O) along the peptide backbone. H-bond forming between these parts of the backbone can lead to common “secondary structure” motifs like alpha helices (those spring-y looking things) & beta strands. Beta strands are often depicted as flat arrows and strands can H-bond with one another to form “beta pleated sheets.” When neighboring strands are running in opposite directions (arrows pointing different ways) we call them antiparallel and when they’re running the same way we call them parallel.
when talking about nucleic acids (DNA & RNA), secondary structure is structure that comes from “base-pairing” interactions between the unique nucleobase parts. With DNA, base-pairing is typically between bases on separate strands. With RNA, base-pairing can also occur between bases on the same strand and RNA often folds up into shapes like hairpins.