Question: I'm new to jQuery and I'm having trouble figuring out how to chain selectors. The goal is to select checkboxes that have the '.restricted' class. Here's the output from my JS console:

```
> $("#capability_panel input[type='checkbox']")
[
<input type=​"checkbox" id=​"jbp_product_workshops" value=​"option1">​
, 
<input type=​"checkbox" id=​"jbp_elevate_creators" value=​"option2" class=​"restricted">​
, 
<input type=​"checkbox" id=​"jbp_trainings" value=​"option3">​
, 
<input type=​"checkbox" id=​"jbp_resources_ask" value=​"option4" class=​"restricted">​
, 
<input type=​"checkbox" id=​"jbp_talent_exchange" value=​"option5" class=​"restricted">​
]    

> $("#capability_panel input[type='checkbox'] .restricted")
[]

> $("#capability_panel input[type='checkbox']").find(".restricted")
[]    

```

I must be doing something dumb, right?

Answer: 
```
$("input[type='checkbox'].restricted") 

```

will match all checkboxes with class restricted

When you give space like `$("input[type='checkbox'] .restricted")` it will look for children elements with class `restricted`

Again `$("#capability_panel input[type='checkbox']").find(".restricted")` will look for elements with `restricted` class inside the parent. Which is not possible as the parent is a checkbox
Selectors in JQuery work like CSS.

If you want the checkbox with the restricted class, you would have to write:
$("#capability\_panel input[type='checkbox'].restricted")

Both $("#capability\_panel input[type='checkbox'] .restricted") and $("#capability\_panel input[type='checkbox']").find(".restricted") will first select checkbox inputs and try to find elements of the restricted class inside them. (