Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 780281
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T20:02:56+00:00 2026-05-14T20:02:56+00:00

typedef struct child_list {int count; char vo[100]; child_list*next;} child_list; typedef struct parent_list { char

  • 0
typedef struct child_list {int count; char vo[100]; child_list*next;} child_list;
typedef struct parent_list
{ char vo[100];
child_list * head;
int count;
parent_list * next; } parent_list;

As you can see there are two structures. child_list is used to create a linked list. And this list will be stored in a linked list of parent list. My problem is to display the child list which in the parent_list.

My desire to get while displaying the linked list of parent_list:

This lists work with this logic. I already made append and other stuff.

For example if I enter ab cd ab ja cd ab

Word    Count    List

ab        3      cd->ja

cd        2      ab->ab

ja        1      cd

The problematic part is displaying child_list which is in the parent_list nodes(List column of output). I don’t know my question is clear please ask for further info.

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T20:02:57+00:00Added an answer on May 14, 2026 at 8:02 pm

    If you just want to print the parent node with its child list you could do like follows

    void print_node(parent_list *parent_node) {
        printf("%s\t%d\t", parent_node->vo, parent_node->count);
    
        child_list *child_node = parent_node->head;
        while (child_node != NULL) {
            printf("%s", child_node->vo);
    
            child_node = child_node->next;
    
            if (child_node != NULL) {
                printf("->");
            }
        }
        printf("\n");
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

typedef struct child {int count; char word[100]; inner_list*next;} child; typedef struct parent { char
I have these structs: typedef struct _Frag{ struct _Frag *next; char *seq; int x1;
typedef struct What_if { char price [2]; } what_if ; what_if what_if_var[100]; int format_input_records();
typedef struct node{ char one; char two; struct node *next; } nodea; I'm thinking
I have a structure typedef struct store { char name[11]; int age; } store;
I have declared the following struct: typedef struct _RECOGNITIONRESULT { int begin_time_ms, end_time_ms; char*
typedef struct Value{ int id; char type; char a; } Value; void fooV(Value v){
typedef struct unit_class_struct { char *name; char *last_name; } person; int setName(person *array) {
typedef struct Model { int recordId; char *name; }Model; typedef struct ModelArray { //keeps
typedef struct { int A; int B; char* C; // problem is here }foo;

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.