Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and the Yahoo Answers website is now in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
?
How to check warranty of nexus 7?
I am intending to get a nexus 7 that has been used.The seller has shown a copy of the receipt.Is it possible to check the warranty from that?
2 AnswersMobile Phones & Plans7 years agoHow to reply back to answers of your questions in yahoo Answers?
2 AnswersYahoo Answers8 years agoProblem in c programming?
Given below is my program
It is a program to create a linked list.
The contents of record.h is given in double quotes
"
/*record.h*/
#ifndef __RECORD_H__
#define __RECORD_H__
struct _Record;
typedef struct _Record{
char *name;
unsigned int age;
struct _Record *next;
} Record;
#endif
"
#include <stdio.h>
#include <stdlib.h>
#include "record.h"
#include <string.h>
Record* createLinkedList(char *fileName);
void deleteRecords(Record **listHead, char *fileName);
void insertRecords(Record **listHead, char *fileName);
void printLinkedList(Record *listHead, char *fileName); /*prints linked list to file*/
void sortLinkedList(Record **listHead);
int main() {
Record *head;
head = createLinkedList("allRecords.txt");
printf("%s",head->name);
printf("\n");
printLinkedList(head,"readRecords.txt");
sortLinkedList(&head);
printLinkedList(head,"afterSort.txt");
deleteRecords(&head,"deleteList.txt");
printLinkedList(head,"afterDelete.txt");
insertRecords(&head,"insertList.txt");
printLinkedList(head,"afterInsert.txt");
return 0;
}
void printLinkedList(Record *listHead, char *fileName) {
printf("Printing linked list to file %s\n",fileName);
FILE *fp;
char s[40];
strcpy(s,fileName);
fp=fopen(s,"r");
{
}
}
void sortLinkedList(Record **listHead) {
/*Sort the linked list by Age (ascending order)*/
}
Record* createLinkedList(char *fileName) {
Record *localHead;
Record ghart;
localHead=&ghart;
printf("Loading records from file %s \n",fileName);
FILE *fp;
char y[40];
int a;
Record *temp;
temp=&ghart;
strcpy(s,fileName);
fp=fopen(s,"r");
localHead->next=(struct _Record*)malloc(sizeof(struct _Record));
localHead=localHead->next;
while(!(feof(fp)))
{
fscanf(fp,"%s",y);
fscanf(fp,"%d",&a);
localHead->name=y;
localHead->age=a;
printf("%d %s",localHead->age,localHead->name);
localHead->next=(struct _Record*)malloc(sizeof(struct _Record));
localHead=localHead->next;
}
localHead->next=NULL;
fclose(fp);
while(temp!=NULL)
{
printf("%s %d",temp->name,temp->age);
temp=temp->next;
}
return temp;
}
void deleteRecords(Record **listHead, char *fileName) {
printf("Deleting records from file %s \n",fileName);
}
void insertRecords(Record **listHead, char *fileName) {
printf("Inserting records from file %s \n",fileName);
}
I get a seg mentation fault in the function where a linked list is to be created.How do i rectify it so that a proper variable of type Record (containing the linked list is returned).
The file that is passed to the createlinked list function is of the form
Name
Age
Name
Age
and so on.
2 AnswersProgramming & Design8 years agocan you get 0 or negative points in yahoo answers?
4 AnswersYahoo Answers9 years agowhere can u get a 64 gb pendrive in coimbatore?
I know from where i can get a 32 gb pendrive. Please give the address of the shop
2 AnswersDesktops9 years ago./ command in linux ubuntu?
I have to use a command ./name details and execute while usually only ./a.out is used for execution.How do I use ./name instead of ./a.out for execution?
2 AnswersProgramming & Design9 years agomy question has been deleted for no known reason?
I asked a question here earlier today about whether more than two controllers can be attached to a ps2 and it was deleted.As far as i know i have not violated any community guidelines.Can someone tell me why it was deleted?
3 AnswersYahoo Answers9 years agocan i attach more than two controllers to my ps2?
For example a computer has four usb ports, but to them you can attach a device with multiple usb ports.Similarly is there a way to play with three or more controllers?
6 AnswersPlayStation9 years agowhat calculator can calculate trigonometric, exponential and logarithmic functions?
please name the calculator[eg: Casio-version whatever ] which has exponential functions like x to the power 4,5... and also powers like 0.1,0.2...0.567,etc. ,inverse functions of logarithmic and trigonometric functions besides the usual stuff
4 AnswersOther - Electronics1 decade agocan you upgrade your pirate cutlass now to the next level available?
mine is level 20 or 21,i think the next possible level is level 25.
1 AnswerVideo & Online Games1 decade ago