Question: I have a array of JSON in which i want to find whether a part of json is present or not.

For eg:
I have this array of json:

```
a = [{'a':'xxxx','b':'yyyy'},{'a':'xzxzxz','b':'asqqqq'}]

```

And I want to know if a = 'xxxx' is present in the array or not?

I have tried this:

```
if {'a':'xxxx'} in a:
    print('1') 
else:
    print('2')

```

But it is giving me '2'

How to do this. Thanks!

P.S: I don't want to use a FOR LOOP

Answer: 
In most situations, this error says that the classloader cannot find the class your code depends on. 

In your case the class named javax/persistence/TableGenerators expected to be on the classpath, but for some reasons it's not.

The TableGenerators class is packaged within *javax.persistence-api-2.2.jar* file.

Before deploying your *.war* file on tomacat, check whether the requierd jars on the classpath - enter into your RESTfullApp.war file and look at the WEB-INF/lib folder, the javax.persistence-api-2.2.jar must be there, otherwise fix your maven build in order to achieve this.

**UPDATE**

It also worth to mention, that exploded .war folder in Tomcat ($CATALINA\_BASE/webapps/RESTfullApp) must have the same layout and contain the same set of files you see in 
 your .war archive, check the javax.persistence-api-2.2.jar is also there. 

In case the mentioned .jar are present on the classpath, I would also suggest you checking the javax.persistence-api-2.2.jar is not broken. 

Sometimes, it happens to be maven downloads broken .jar archives which might cause the error you see.
At least, you can try to unzip this jar file and check if there will be any errors while extracting this jar.
Bad news... The current config I'd display works properly in the server. That probably means the problem I'm getting is from a problem between Tomcatn and Windows. For now the test are returning a 404 code (the catch exit of the code) but now all is about working in the service and make some tests before publishing the service. Any way, thanks for the help.