regex for [2,4,p^t,2p^t] where p is prime and t is any positive integer

30 Views Asked by At

i was learning the cryptography where i got the assignment for building the primitive root for the given number so before doing the calculation i need to check that a number must be any of these form

[2,4,p^t,2p^t]

is their any regex that can check that?? if not then is their any way i can check that number is built up from this form??

0

There are 0 best solutions below