how to join two different JSON into single JSON in C#
<p>My first JSON is as follows</p>

<pre><code>[{
    "UserId": 4,
    "FirstName": "rupesh",
    "LastName": "Abc",
    "Email": "abc@gmail.com",
    "Gender": "Male"
}]
</code></pre>

<p>My Second JSON is as follows </p>

<pre><code> [{
    "AccountId": 2,
    "AccountName": "rupeshinfo",
    "AccountDomain": null,
    "RoleId": 1,
    "UserId": 4
}, {
    "AccountId": 3,
    "AccountName": "Rameshinfo",
    "AccountDomain": null,
    "RoleId": 2,
    "UserId": 4
}]
</code></pre>

<p>the result must be</p>

<pre><code>{
    "UserDetails": [{
        "UserId": 4,
        "FirstName": "rupesh",
        "LastName": "Abc",
        "Email": "abc@gmail.com",
        "Gender": "Male"
    }],
    "AccountDetails": [{
        "AccountId": 2,
        "AccountName": "rupeshinfo",
        "AccountDomain": null,
        "RoleId": 1,
        "UserId": 4
    }, {
        "AccountId": 3,
        "AccountName": "Rameshinfo",
        "AccountDomain": null,
        "RoleId": 2,
        "UserId": 4
    }]

}
</code></pre>