A compound of the formula: or a pharmaceutically acceptable salt of any of the foregoing, wherein: Ring A is: R B1 is hydrogen; W B is CR B2, wherein R B2 is hydrogen, halogen, -CN, -OR B2a, -N(R B2a) 2, unsubstituted C 1-6 alkyl, C 1-6 alkyl substituted with one or more halogen, or unsubstituted carbocyclyl, wherein each instance of R B2a is independently hydrogen, unsubstituted C 1-6 alkyl, or C 1-6 alkyl substituted with one or more halogen; L 1 is --NH--; L 2 is -NHC(=O)-, -C(=O)NH-, -NHS(=O) 2 -, -N(C OC(CH 3) 3)-, -N(Boc)-CH 2 -, -NH-, --NHCH 2 -, -NMeCH 2 -, -OCH 2 -, or -NHCH(CF 3)-; each instance of R C is independently halogen, =O, -CN, -OR C1, -N(R C1) 2, -C(=O)N(R C1) 2, -C(=O)OR C1, unsubstituted C 1-6 alkyl, or C 1-6 alkyl substituted with one or more substituents independently selected from the group consisting of halogen, -CN, OR C1a, and -N(R C1a) 2, wherein each instance of R C1 and R C1a is independently hydrogen, unsubstituted C 1-6 alkyl, or C 1-6 _alkyl substituted with one or more halogen, or two R C groups are taken together to form an unsubstituted heterocyclic ring or an unsubstituted carbocyclic ring; n is 0, 1, 2, 3, or 4; R D is halogen, unsubstituted heterocyclyl, or morpholinyl; p is 0 or 1; R E is R E1 is selected from the group consisting of hydrogen, halogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, unsubstituted heteroaryl, -CN, -CH 2 OR E1a, -CH 2 N(R E1a) 2, -CH 2 SR E1a, -OR E1a, -N(R E1a) 2, -Si(R E1a) 3, and -SR E1a, wherein each occurrence of R E1a is independently selected from the group consisting of hydrogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, and unsubstituted heteroaryl, or two R E1a groups are joined to form an unsubstituted heterocyclic ring; R E2 is hydrogen or unsubstituted alkyl; and R E3 is selected from the group consisting of hydrogen, halogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, unsubstituted heteroaryl, -CN, -CH 2 OR E3a, -CH 2 N(R E3a) 2, -CH 2 SR E3a, -OR E3a, -N(R E3a) 2, and -SR E3a, wherein each occurrence of R E3a is independently selected from the group consisting of hydrogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, and unsubstituted heteroaryl, or two R E3a groups are joined to form an unsubstituted heterocyclic ring. Ring A is: R B1 is hydrogen; W B is CR B2, wherein R B2 is hydrogen, halogen, -CN, -OR B2a, -N(R B2a) 2, unsubstituted C 1-6 alkyl, C 1-6 alkyl substituted with one or more halogen, or unsubstituted carbocyclyl, wherein each instance of R B2a is independently hydrogen, unsubstituted C 1-6 alkyl, or C 1-6 alkyl substituted with one or more halogen; L 1 is --NH--; L 2 is -NHC(=O)-, -C(=O)NH-, -NHS(=O) 2 -, -N(C OC(CH 3) 3)-, -N(Boc)-CH 2 -, -NH-, --NHCH 2 -, -NMeCH 2 -, -OCH 2 -, or -NHCH(CF 3)-; each instance of R C is independently halogen, =O, -CN, -OR C1, -N(R C1) 2, -C(=O)N(R C1) 2, -C(=O)OR C1, unsubstituted C 1-6 alkyl, or C 1-6 alkyl substituted with one or more substituents independently selected from the group consisting of halogen, -CN, OR C1a, and -N(R C1a) 2, wherein each instance of R C1 and R C1a is independently hydrogen, unsubstituted C 1-6 alkyl, or C 1-6 _alkyl substituted with one or more halogen, or two R C groups are taken together to form an unsubstituted heterocyclic ring or an unsubstituted carbocyclic ring; n is 0, 1, 2, 3, or 4; R D is halogen, unsubstituted heterocyclyl, or morpholinyl; p is 0 or 1; R E is R E1 is selected from the group consisting of hydrogen, halogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, unsubstituted heteroaryl, -CN, -CH 2 OR E1a, -CH 2 N(R E1a) 2, -CH 2 SR E1a, -OR E1a, -N(R E1a) 2, -Si(R E1a) 3, and -SR E1a, wherein each occurrence of R E1a is independently selected from the group consisting of hydrogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, and unsubstituted heteroaryl, or two R E1a groups are joined to form an unsubstituted heterocyclic ring; R E2 is hydrogen or unsubstituted alkyl; and R E3 is selected from the group consisting of hydrogen, halogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, unsubstituted heteroaryl, -CN, -CH 2 OR E3a, -CH 2 N(R E3a) 2, -CH 2 SR E3a, -OR E3a, -N(R E3a) 2, and -SR E3a, wherein each occurrence of R E3a is independently selected from the group consisting of hydrogen, unsubstituted alkyl, unsubstituted alkenyl, unsubstituted alkynyl, unsubstituted carbocyclyl, unsubstituted heterocyclyl, unsubstituted aryl, and unsubstituted heteroaryl, or two R E3a groups are joined to form an unsubstituted heterocyclic ring.