Replaced list comprehensions inside all/any/sum with generator expressions

PiperOrigin-RevId: 222429778
diff --git a/configure.py b/configure.py
index 234561d..0b16fe1 100644
--- a/configure.py
+++ b/configure.py
@@ -859,7 +859,7 @@
     cuda_toolkit_paths_full = [
         os.path.join(cuda_toolkit_path, x) for x in cuda_rt_lib_paths
     ]
-    if any([os.path.exists(x) for x in cuda_toolkit_paths_full]):
+    if any(os.path.exists(x) for x in cuda_toolkit_paths_full):
       break
 
     # Reset and retry