If user has 1 post then dont let him create new one [closed]

You can use count_user_posts function.
If the posts are getting saved as WordPress posts then it can be done by the snippet below:

if (is_user_logged_in()){
    $userPostCount = count_user_posts(get_current_user_id());
    if ($userPostCount > 1){
        $user = new WP_User(get_current_user_id());
        $user->add_cap('publish_posts',false);
    } else {
        $user->add_cap('publish_posts',true);
    }
}