QuickBooks Online 2024. Sales by product and service report. Get ready and pack some trail mix because we're hiking on QuickBooks Online, our audit trail to success. Here we are online in our browser searching for QuickBooks Online Test Drive looking for the result that has Intuit.com and the URL Intuit being the owner of QuickBooks selecting the United States version of the software and verifying that we're not a robot. Opening up financial statement reports like we do every time. Reports on the left hand side in the favorites. We're going to be right-clicking on the balance sheet to open link in a new tab. Right-clicking the profit and loss. Once again, opening the link in a new tab. Tapping to the middle closing up the hamburger and changing that ranging. 010123 tab, 123123 tab. Run it to refresh it. Let's go to the right tab. The right hand side closing the hamburger. Once again, bringing it back to 2023. 010123 tab, 123123 tab. Run it to refresh it. That's the setup process that we do every time. These being the two major financial statement reports, we're now looking at other reports. Most other reports giving more information about one or multiple line items on these main two financial statement reports. This one, this time, we're looking at a report that's going to give us more information about the income or revenue line items given it by the service item or inventory item. Let's go to the first tab to open that new report up. Going to the reports on the left-hand side, closing up the hamburger. We'll scroll on down. We're looking at the sales items. So notice the title here. Sales and customers would make us think that most of these reports are going to give us more information about the line items on the income statement related to sales, which is being used to kind of be synonymous or the same as income or revenue. And customers with customers were thinking sales because we sell stuff to customers, but sometimes the customer reports you would think might tie out to the accounts receivable as well as we track the AR collecting from customers. But most of those reports are up here in the who owes you money that we talked about before. So these you would think mainly being our sales related reports. So we looked at last time the income by customer and the sales by customer. This time we want to take a look at the sales by product, both the detail and the summaries. Let's right click on the summary first, open link in a new tab, and then I'll also right click on the detail at the same time and open the link in a new tab. Let's go to those two tabs, do some formatting, bringing the date range back, closing the hamburger. O3 is where we want to be. O10123 tab, 123123 tab, run it to refresh it. Once again, tab into the right, closing the hamburger. O3 is where we want to be. So O10123 tab, 123123 tab. O3 is where we be now. That's good. Okay, so if I go back to the income statement, you'll recall the income statement, performance statement, measuring how well we did over a certain time range, usually represented in month or year. We can see that with the range up top, January through December. Sometimes people have a tendency to record income line items by either customer, which we touched on last time, which is something that we don't want to do. Why? Because we have another report usually that we can then provide income by customer. So you want to keep your income line items nice, tight, clean, representing what it is that you're selling in a grouped format and not giving too much detail that you're trying to put in the income section of the income statement because you have the other reports to drill down on that more detail usually. We'll get to the exception in a second. Also, the next thing that people typically do is they make too many income line items by the things that they sell, meaning the service items. If you're a bookkeeper, we make too many, if we do it like accounting, we make too many line items saying this is accounting for this type of bookkeeping versus that type of bookkeeping versus every line item that we're charging for, every product or service. And if we're in a retail store, we might tend to make an income line item for every single type of product we sell as opposed to giving the general group or category of things that we sell on the income statement and then using our other reports to give us more detail, breaking it out by the things that we sell by product. So just to quick recap those products and services. If I go to the first tab over here and scroll down a bit, open the hamburger and we go into the sales line. The products and services are on the right. These are the things that we sell, right? These are the things that are going to be populated on the invoices and sales receipts as we sell them and they're going to be the services or physical inventory that we are selling. So that means that on the income statement, we have our income that's going to be given to us by the product. So now let's just give a quick reminder that this will only work. This report will only work if when you record your income, you're doing so with the income forms of invoices and the sales receipts. If you're using bank feeds to record your revenue, then you're most likely using a deposit form, which isn't really the form most designed to record income. So in that case, you might lose some detail of the sub ledger reports related to sales, like sales by customer and sales by item, because you might not have any items in particular with the deposit form of sales that you're recording to income. So you won't have this report. So in that case, then it's most likely you're doing that for something like gig work or something like that. So in that case, it might make more sense then to record your income probably by who you sell it to. If you've got income from YouTube or whatever the income's coming from. If it's a platform, you're probably going to record it by platform, because that's this kind of business that usually works well in that kind of system. You'll lose the more detail of these other reports, but it'll probably be worth it because it'll be nice and easy to do that way. However, if you have a full service accounting system where you're at a cash register and you're using sales receipts or you're invoicing clients with an invoice and tracking the accounts receivable, then you should be able to tie out your income lines and have the subsidiary reports by customer and by item. So if we go into this by item report, I'm in the balance sheet, whatever, if I go into this item report, we have the quantity of things that we sold. When we hear the term quantity, we might be thinking physical units or inventory type items as opposed to service items, but in this context, the term quantity means any kind of item, whether it be service item or inventory item. In other words, if I go to this first tab over here and I hit the plus button and we select an invoice or a sales receipt, the sales type forms, and we're imagining we're making a sale to a particular customer, we choose our items down here that have already been set up.


Box 13 with the star of Paramount Pictures, Alan Ladd, as Dan Holiday. Box 13. Box 13. Box 13. Hi, Mr. Holiday. What do you say? Where's that society face, please? Hiya, Holiday. Hiya. Jerk the first paragraph in that Simmons story. Hiya, Susie. Hiya, Mr. Holiday. What's in Box 13? You are listening to Box 13 starring Alan Ladd as Dan Holiday. Now for Box 13 starring Alan Ladd as Dan Holiday. Here I am again standing at the wanted counter of the star times looking for what? The idea for a story. I could have stayed here as a reporter. I could have been searching for facts instead I'm fumbling for fiction. Instead of a blonde I'm meeting a deadline. Instead of Chanel number five I'm heading for a sniff of printer's ink.  Hi. What's that, Susie? I said there's a letter in Box 13 for you. It's special. Special? Special delivery. It was mailed only a couple of hours ago. Something like that could be important. Could be. Could be adventure. Could be. Could be a girl. Could be. By the way, Susie, how come you're working so late to see me? Oh, my boss asked me to. He's paying me overtime. Time and three quarters. Time and three quarters? I held out for double time when he offered me time and a half. What happened? Oh, we affected a compromise. Goodbye, Susie. Special delivery, huh? Well, this could be very important, also it couldn't. Well, come on. Open it up, Holiday. You haven't got all night. I'm in terrible trouble. Please come to room 718 at the Bradford Hotel. Hurry. Signed Agatha Marsh. That sounds urgent. Who are you, young man? What do you want? I'm the man from Box 13. I'm looking for Agatha Marsh. I'm Agatha Marsh. Come in. Come in. Your Agatha Marsh?  Never can tell who might be snooping around the hall. I find a chair and sit down. Now, what's your name? Dan Holiday. Well, Mr. Holiday, I don't believe in drinking, or I'd offer you one. But I have got some sauerkraut juice in my thermos bottle. Oh, no, thanks. It's the same.  I liked your ad in the paper. Adventure wanted. Oh, any place do anything. It was just what I needed. Well, thanks again. Now then, what's your charge? Charge? For helping me, your fee. Oh, that. No charge, Miss Marsh. Are you trying to be chivalrous? No, you see, I'm a writer. I'm looking for ideas. If I get a good idea, I consider I've been well-paid. That seems a little silly. Might I ask just what your trouble is? Oh, you don't think a girl my age could get into trouble, do you? Well, you look like a very charming old... Oh, I'm sorry. Oh, lady, oh, lady. Let's not beat around the bush. Now, no doubt you want to know a few things about me. Well, that would be very interesting. Yes, well, I live in Muncie, Indiana, alone. I've got a big house and an independent income. Every year I go someplace for a vacation, and this year I came here. Uh, is that all? Isn't that enough? But the letter you wrote, may you said you were in terrible trouble. Well, I am. If anyone ever finds out about this, I don't know what'll happen. Finds out about what?  I want to show you something. Look. On the floor. Well, that's a dead man lying there. Well, this would make a good opening chapter for a story. Young man goes to help charming old lady who is in terrible trouble.  Corpse? Hey, wake up, holiday. This is the real thing. Now. Now do you believe me, young man? When did you find him? Just before I wrote you that letter. Before you wrote the letter? Well, that's hours ago. I know, but what could I do? What could you do? Miss Marsh, you could call the police. And get my name in the papers. Have all the folks back in Muncie know there was a dead man in my room? Oh, no. Miss Marsh, listen to me, please. There's a dead man in that closet. There's a law about dead men. We have to notify the police immediately. You can go to jail for hiding a body. Fiddle sticks. But Miss Marsh, look at this man. He's been shot at close range. There are powder burns on his coat. I know. I examined him before I wrote you. You see, I read all the current detective stories. Detective stories? This isn't a story. This is the real thing. I know. Why don't you try to prove that I did it? With what? A cap pistol?  But this is going to be tough. Well, don't get so excited. A girl my age could kill a man if she wanted to. Rub him out, as they say in the murder mysteries. Please, Miss Marsh, be sensible.  Now pick up that phone and call the police right away. Mr. Holliday, in all seriousness, I can't do it. Think of what my lifelong friends would say. Yes, yes, I know it doesn't look good. I can see the headlines now. Prominent, munchy pioneer woman found with dead body in hotel. Oh, please, Mr. Holliday, help me. Well, I don't know. This is a little out of my department. Just this once, Mr. Holliday, I've never asked for help before. I'm an old woman. Well, all right. What do you want me to do? I want you to help me get rid of the body. Get rid of the body? Now, look, Miss Marsh, you're not serious. You didn't mean that. No, you don't know me. I fully intend to get rid of that body. Okay, go right ahead. It's your corpse. And you're going to help me? No, no, I'm sorry. Try a bell. And have him snitch to the desk clerk. Besides, you advertised for adventure. But this isn't adventure. It's a nightmare. Come on, Miss Marsh. Let me notify the police. Now, there's a broom closet down the hall. That's very interesting. I just remember I'm eating someone in the lobby. I take the body there myself, but I'm not strong enough. Goodbye, Miss Marsh. I'll scream. Go right ahead. The hotel detective will show up. Just a man I'd love to see. And I'll tell him you killed that man. Oh. Now, would you help me? Suppose we get caught. Then you'll help me. Now, wait a minute. You said we. Now, I'll open the door and watch the hall. Case the joint, as they say, in the mysteries.  You're strong. You can do it. Oh, sure. I'm strong all right. But not in the head. Oh, this can't be happening to you, Holiday. You can't be dragging a body down the hall of the Bradford Hotel. You know better. And as soon as you can get away from this charming but cracked old gal, you're going to talk to the police. Harry. Harry. I'll open the closet door. Put him in the room right there. Stick him in good. I must be crazy. Good. Now back into my room before anybody sees us. There. Wasn't that easy? Easy, she says. Well, I must say you carry out your part very well. What's next in this little scheme of yours, Miss Marsh? Why don't you know? We have to find out who killed that Michael O'Brien. You know who he is? What I do now? I went through his pockets. Frisk him, as they say in the stories. Well, that cuts it. You stay here. I'm going downstairs. Who's that? Just keep cool. I'll handle everything. Oh, I can't believe this. It just can't happen. My name is Kling, Lieutenant, homicide bureau. Oh, come in. Come in, won't you? I intend to. Holliday, what are you doing here? Hello, Lieutenant. Oh, do you two know each other? Never mind the social chatter. I thought this was some kind of a gag, now I'm sure of it. Holliday, just what are you trying to dream up? If I told you, Kling, you'd never believe me. Sit down, Lieutenant.  Well, I don't mind if... Some what? Sauerkraut juice. Oh, no thanks. Now listen, somebody, some crackpot, phoned in the tip that there was a dead man in this room. Well, Lieutenant, how can you say such things? Lieutenant, now listen. You'll be quiet. Miss Marsh, mind if I have a look around? Not at all, not at all. Here's the closet. Heather, you can see for yourself, Lieutenant. There's nobody there. I got your name from the desk clerk, Miss Marsh. Maybe you better tell me about yourself. I can tell you all about it. I'm talking to Miss Marsh. Are you Miss Marsh? Right now I think I'm dead. You will be if you keep interrupting.  Certainly. I live in Muncie, Indiana. I arrived this morning for a two-week vacation. I'm well known back there, and you can find out everything about me if you care to wire. How did you happen to meet Mr. Holliday here? Look, Lieutenant, if you'll permit me to tie... I'm asking a lady. I went to school with his mother. That's what I did. Oh, see. Well, I guess it was the work of some would-be comic. But I had to investigate it just the same. Well, of course you do. Oh, but Kling, listen. Goodbye, Miss Marsh. So long, Holliday. But Kling, wait, I want to go with you. Why don't you two have a fast game of hearts? Mr. Holliday wasn't that thrilling, just like in the Maxine's. Miss Marsh, you're going to stay in this room until I get Kling back here. Oh, no, no, no. I want to solve this case myself. I wonder how Kling found out that... Miss Marsh? Yes.  Of course I know. It was I. What in the world are you doing? I made the call from the corner drug store a little while ago. I wanted to throw the lieutenant off the trail, like they say. You know what I say? No, what? You're going down to police headquarters to tell the truth. Oh, just a second. Excuse me, please. Yes? Yes, this is Miss Marsh. Oh, you did? I thought so. It should have had 817 instead of this room. Oh, no, don't bother. I like it here. I knew it. I knew it all the time. What did you know? That was the room clerk. He got my reservation mixed up. I was supposed to get 817 and I got 718 instead. You mean the person who killed Michael O'Brien wanted to get back in here to remove the body? No, no, no. It doesn't sound reasonable. No, it doesn't. Well, guess who was supposed to get this room? Never mind. We're going to police headquarters. It was Tony Bascari. Tony Bascari? He's the biggest racketeer in town. He's dynamite. Miss Marsh is deadly. I know Mr. Holliday and I love it. Oh, no. You are listening to Box 13 starring Alan Ladd as Dan Holliday. Now back to Box 13 starring Alan Ladd as Dan Holliday. 2 o'clock in the morning and I can't go to sleep. That little old girl has me worried to death. She wouldn't go to the police headquarters and when I went down and talked that clingy act as though it were a big joke and sent me on my way. Hello. This is Agatha Marsh. Now what? Where are you? At the hotel. I went up to see Tony Bascari. You what? Miss Marsh, don't you know that's the worst thing you could have done? I had to talk with him. I put the heat on him as they say in the murder mysteries. And you're still alive? I accused him of killing that O'Brien man. I came right out with it. But of course he wouldn't admit a thing. What are you expecting to do? Break down and confess? Well, I think I've got him on the run. But I'm worried. Oh, if I had Tony Bascari on the run, I'd be worried too. Because when I came back I discovered someone had searched my room. Will you call a police? You should have done it a long time ago. Oh, no, no, no. I couldn't. I want you to come over right away. At 2 in the morning? Mr. Holliday, someone's trying my door. Hang up quick. Call the room clerk. Mr. Holliday, I'd... Hurry, I said!  In your clothes, Holliday, because here we go again and don't forget your boy, Scott Badge. You'll make the beaver patrol tonight. The clerk's yet to call the desk. I wonder... No, she would have screamed. Someone would have hurt her. It's open. Cleaned out completely. No mishmash, no clothes, no nothing. Not even a piece of note paper. Hey, what's this? Paper airplane. Like the ones I used to make in school. But why should she be making paper airplanes? Airplanes. The airport. That's where they took her. Keep that motor running. I'll be right back. How many people around this hour of the night? Oh, there she is. And the man with her has his hand in his pocket Don't think it's there because it's cold. What I need now is a little fast talk and a little faster action. Okay, I'll take over from here. Who are you? What are you talking about? The old doll. Baskerry wants her back. Baskerry told me to put her on a plane. I'm doing it. Yeah, he changed his mind. He wants her back. I don't think so. Besides, I never saw you before. I told you, if you don't turn her over, Baskerry might get sore. When did he call me? It's only a half hour ago. I was still at the hotel he could have called. And spilled everything over our phone? Yeah, nuts? This don't sound right. Yeah, forget it. Taking the old doll back with me. Wait a minute. I'm going to call Tony first.    Show me something that'll prove Tony sent you. Got a match? Stop stalling. This is a gun in my pocket. Let's talk to Tony. I've got some matches here. Thanks. Here. Give him Mr. Holiday quick. Oh, not so fast. I'm not as young as I used to be. You should have remembered that before you got mixed up in this.  What did you do to that guy anyway? I...  I might have guessed it. Now, Miss Marsh, what happened at the hotel? Well, I hung up when I heard him trying the door, but I was too late. The door was unlocked. So it was Tony Bascari, huh? He wanted you out of town fast. Oh, but they were very nice to me. You can thank your lucky stars for that. Usually Bascari's enemies wind up in some ditch. I didn't see him again. That man, the one you knocked out at the airport, was the one who came in my room. Well, you must have the goods on Bascari.  But why didn't he take him out of the hotel right away? But there was a convention there last night. The whole place was literally crawling with people. Oh, that's the reason. All that paper airplane that was fast-thinking, Miss Marsh. Oh, thank you. Well, now we can go back to Bascari. We've got the goods on it. We can crack the cakes like they say in the murder mysteries. Miss Marsh, I've got news for you. We're not going to see Bascari. We're not? Well, where are we going?  Well, Holliday, what happens now? You've taken Miss Marsh to Kling's office. She looks at him. He nods her into his private office. And suddenly she comes out smiling.  You stay here, Holliday. You can't let her walk the streets alone. Bascari will get her. Forget it. I've got a man telling her. Okay, okay, but what happened in that office? What did she tell you? Plenty, my friend. She preferred charges against you. She preferred charges against me? Now what are you talking about? Kidnapping. I kidnapped her? You took her off the plane by force, didn't you? Listen, Kling, that little old lady is a whodunit happy. She'll get herself killed. There really was a body in the hotel, you know. Look, Holliday, do you know what you're saying? Sure, I know what I'm saying. There really was a body in that hotel. Holliday, why didn't you tell me? I tried to, twice. Once in the room in the last time when I came in here. Now, think, Holliday, carefully. Where is the body? In our broom closet down the hall. I put it there. You put it there? Yes, I put it there. Holliday, get out of here. Well, Holliday, now you're fixed. Even Kling looked at you like those things and your belfry weren't bats. They're more like eagles. But you're in it now, so you've got to follow through. And that indicates a fast ride over to the Bradford Hotel. Oh, clerk. Hey, clerk. Yes? I'd like to find out who occupied Agatha Marsh's room the day before she did. That question is highly irregular. Oh. Then here's a $10 bill that's highly regular. Oh, let me think. She has 7.18. She checked in day before yesterday. Yes? The man who had the room before that was a traveling salesman in Lady Suits, I believe.  She must be in this hotel someplace. Her room's empty, but she must be in the hotel. She must be around, but where? What are you worrying about, Holiday? You couldn't wait to get rid of her. Now you can't wait to get her back. You're a character who belongs back in the Middle Ages with a 10-union suit for cold nights. She'll probably show up safely with that detective tailing her. The broom closet. Wonder if the dead man is still in there. It must be. Kling hasn't showed up yet. Oh. Oh, hello, Mr. Holiday. Miss Marsh, what happened? How'd you get in that closet? Isn't this thrilling? No, it isn't. There was a detective trailing me, but he was knocked unconscious, sharp as they say in the murder mysteries. And you were brought up here? By the same man who tried to put me on the plane. He hit the detective, put me in the car, and brought me here. Well, you two, what are we playing now? Where is the man I put on you, Miss Marsh? He was hit over the head, Lieutenant, and I'm sure he's all right now. This is the closet where you said the body was? Was, is right, Lieutenant. Let me take a look. You know what I think, Holiday? What? I think both of you crackpots are making this all up. I don't believe there ever was a body. Kling, you have my word for it. Your word doesn't mean as much as a Chinese dollar. Kling, listen. They brought her back here, locked her up. They took the body away, didn't they, Miss Marsh? They're going to sink it in cement, as they say in the murder mysteries. Bascaries in his room. I'll go up and talk to him. Surely, put the heat on him. Just once more, I'll play with you, kiddies. Come along. Where? Miss Marsh's room. I'm locking you pixies in till I get to the bottom of this. Kling's been gone 15 minutes. I wonder what's happening up there. Not much. I haven't heard any shooting. I haven't heard any... In that case, how could a man be shot here... and that shot not be heard? Well, it's very easy, Mr. Holiday. The killer would use this. Miss Marsh, now, where'd you get that gun? Just took it out of the drawer. It was here all the time. Well, put it down until Kling returns. But I just want to show you why the shot wouldn't be heard. What do you mean? Would you excuse me, please? See this bath towel, Mr. Holiday? Yes, what about it? A smart person would take the gun like this. Wrap the bath towel around it like this. You know, Miss Marsh, you found out a lot since you came here. Oh, yes, I've done all right since early this morning. Early this morning? But the clerk said... I talked to Donnie Biscari and he said... Kling, look out! Miss Marsh, give me that thing. You shouldn't have moved, Mr. Holiday. I was really shooting at you. I asked this all about Holiday.    Miss Marsh, you did kill him, didn't you? Then you called me and you got Kling to come up here and catch me dragging the body away. Only he came a little late, as usual. Now, wait a minute, Holiday. Then when you couldn't pin it on me, you tried to hang it on Donnie Biscari. Now, what did you do with the body? I went back to the closet in this room.  It was easy. I got him to turn around and hit him over the head with my purse. Why did you kill Michael O'Brien? Did you have something against him? No, no. I never saw him before.  I saw play once. I liked those ladies in that play. They killed lots of people. I wanted to also. Only I should have done it like the ladies. You don't mean arsenic and old lace? Yes, and I should have worn the lace and given you the arsenic. Well, Holiday, you're back in your apartment again. The sun is shining through the window, a sun you might never have seen again. You know, I've got an idea for you, Holiday. Give up this business and go into something quiet, like night watchmen in a cemetery. Holiday! Well, what's that, Kling? They examined the old girl down at the psychopathic ward of the city hospital. She's bad. He is alone. You're telling me. I saw that in her eyes when she wrapped the towel around that gun. But what happened to Bascari and his stooge? When she heard he was the room above, she tried to pin the body on him. Oh, so he tried to get her out of town in self-defense.  You can say that again and again and again. Oh, just a minute. Hello, Mr. Holiday. Susie, what are you doing up here in my apartment? Why aren't you down at the Star Times? Well, my boss and I have been talking about another compromise. Another one? He wants to fire me and I want to quit. Oh, but Susie, if you left the paper, what would I do for my mail? I was thinking maybe you'd like to hire a good combination stenographer and secretary, huh? That's you. That's me. Well, I don't know Susie, but as they say in murder mysteries, I'll have to think it over. You better think fast. Good help is hard to find. Goodbye, Susie. Next week, same time, Alan Ladd stars as Dan Holiday in Box 13. Alan Ladd appears through the courtesy of Paramount Pictures and may currently be seen in Wild Harvest. Box 13 is written and directed by Ted Hediger. Original music was composed and conducted by Rodie Schrager. This is a Mayfair production.


In this video, we present the solution to question number 11 for practice exam 2 for math 1060, in which case we're asked to evaluate the trigonometric expression sign of sine inverse of 3 fifths plus tangent inverse of 2. And we need to write the evaluation in exact form. So just throwing this in your calculator and getting some number doesn't do you a bit of good. So don't do that. So what we're going to do is we're going to first treat each of these trigonometric functions as angles. I'm going to call this first one alpha and the second one beta. You can call it A and B if you prefer. It doesn't really matter. So we're trying to compute sine of alpha plus sine of beta. Using the angle sum identity for sine, we say this is equivalent to sine of alpha cosine of beta plus cosine of alpha times sine of beta. In which case, then we have to do sine of alpha, cosine of alpha, cosine of beta, sine of beta. So we need to think of these angles. How do we, how do we compute these other ratios, right? So starting with sine inverse of three fifths here, start with alpha. Notice we've said that alpha equals sine inverse of three fifths. That equates to being, to mean to us that sine of alpha is equal to three fifths. So we're going to construct a triangle associated to exactly that value right there. So we have a right triangle for which then we identify that alpha is the triangle we're considering here. Sine is of course the opposite over hypotenuse by the Pythagorean equation. The other side is going to equal four. So we know that sine of alpha is three fifths. Then we also know that cosine of alpha, which we need to know is going to be four fifths. Great. Let's move on to tangent inverse of two, which is beta. So we have that beta is equal to tangent inverse of two. This tells us that tangent of beta is equal to two. And I'm going to write that as a fraction two over one. And so if I think of my triangle here, you're going to want to draw two triangles to help you out. Like so. This will be the triangle associated to angle beta. So tangent is opposite over hypotenuse. And then by the Pythagorean equation, the other side will be the square root of five. So we know tangent of beta. We need to know sine and cosine of beta. So sine of beta is going to equal two over the square root of five. You don't have to bother rationalizing the denominator or anything. Cosine of beta is going to equal then one over the square root of five. And so using these values, we can plug it into the formula above. So sine of alpha, remember was three fifths. Cosine of beta was one over the square root of five. Cosine of alpha was four fifths. And then cosine, excuse me, sine of beta was two over the square root of five. So multiplying these things together, you're going to get three over five root five. And then you're also going to get eight over five root five. For which you don't have to worry about rationalizing the denominator, but they do have a common denominator, so we can add those together. So the final answer is going to be 11 over five times the square root of five. Now you are allowed to calculate in this problem. What you can do is you can check with your calculator that 11 divided by five times square root of five is equivalent to this number if you had plugged it in into your calculator earlier, of course. And it doesn't actually matter if it's in degrees or radians in that regard because it'll just get a number in the end. But for full credit, you need to have this as the exact form 11 over five root five or something equivalent to that. And you also need to show these type of right triangle diagrams and how you unravel this thing to get 11 over five root five.


Hello, hi everyone. I am Sanjay Gupta. I welcome you on Sanjay Gupta Tech School. So today we are having day 18 of C and C++ coding bootcamp. And in today's session I will be discussing about string in C programming. So before starting the session, I just want to show you the session tracker and the sessions which we have conducted so far. So you can see I started this bootcamp in June and so far we have completed 17 sessions.  And these sessions we have covered so far. So if you have not followed all the sessions, so you can. And in the middle you can see I just provided some pre-recorded video links as well where lots of practice exercises are available. So today we are having day 18. And in this session I will be discussing about strings and C programming, right? So moving on to the topic. So before starting the session, I just want to show you a few things about me. So if you don't know about me and you want to know who is your instructor, so this slide will help you to know about me. So I have 16 plus years of experience. I have worked in both education industry and IT industry and helping students, freshers and professionals so that they can ramp their career in Salesforce ecosystem or you can say in IT world. So moving forward, consistency is the key. So please do regular practice. Without practice you won't be able to understand programming. And this is self-help group for this coding related stuff. So you can join this and you can ask questions here. And if you want to receive timely notification, you can follow Sanjay Gupta Tech School on YouTube, LinkedIn, Instagram and Telegram. And all the important links are available in the video's description. Okay. So with this note, I just want to start the session for today. So today's topic is string. String is very much important and this topic is available in C programming, C plus plus programming, Java programming, as well as in Apex programming. So everywhere we use strings, right? And strings are basically collection of characters. Okay. So as you can see here, few points related to strings are written. So we will be discussing these first of all. And in simple terms, if someone asked like what is string, so a string is a collection of one or more than one characters terminated by a null character. So this null character is important in C programming. So in C programming, if you are creating any string and it is having more than one or one characters, so at the end, you need to provide this backslash n, which is important. And we have one terminology which is known as ASCII value. So ASCII stands for American Standard Code for Information Interchange. So this null is basically a character backslash zero. This backslash zero null characters, ASCII value is zero, right? So whenever you will be creating any string, so this null will be available automatically, you just need to know like null is required at the end of the string, right? And its ASCII value is zero every time. And string constants are enclosed in double quotes. So whenever in any programming language, like if you provide any string, then we use double quotes. And in some programming languages, we use single quotes as well. So in Apex, basically we use single quotes, but in C programming, C++, Java, for string constants, we use double quotes. And a string can contain alphabets. Alphabets means uppercase a to z or lowercase a to z, then we have digits from zero to nine, and then we have spatial symbols. So other than alphabets and digits, whatever symbols are available on keyboard, those are spatial symbols, and they can also be part of string. So combined alphabets, digits and spatial symbols, all these character combination becomes a string, right? So this is overview about string. Now, let's understand how in C programming, we can declare a string, right? So with the help of this slide, you will be able to understand how we can create a string, right? So here declaration is mentioned. So for creating string in C programming, we use data type care, right? So in other programming languages, you might be using string directly string as a data type. But here in C programming, we have care as a data type. And then we need to provide name of the string, right? And the size size is also important, like how many characters you will be storing. Okay. And at bottom, you can see the example we have data type as care, then name of string is str and size is 10. So it means this string can store 10 different characters. So if size of string is 10, then it can only contain nine characters, because null also occupies one byte. So as I told you in the beginning, if you are creating a string, so at the end of string, null character will be available, right? So if size is 10, so total nine characters will be there and at the end, null character will be present. Okay, so this way, we'll be able to create the string. Now how its memory location look like. So I hope you have gone through array related sessions, which I delivered in last week. So I explained to you how we can create one day array, how we can create 2D array. So string is basically similar to one day array, right? So in one day array also in one row, we store similar type of values. So string is kind of one day array, right? So here you can see we have care str 10. So this is one day notation, but here we will be storing characters and all those characters will be terminated by null. So that's why this character array is spatially treated as string. Okay, and memory location, you can see total 10 blocks are available. And at the bottom, you can see indexes are also available, because in array, every location has a unique index, which basically starts from zero, and it ends till like total number of size minus one. So if sizes 10, so last number of index will be 10 minus one. And each character occupies one byte of memory if we talk about C programming specifically. So above string occupies 10 bytes of memory. Okay, so this is very important to know like whenever you are creating any character array that you will be using as a string. So how its memory location look like. So it is similar to one day array. And this way you can assign values to character array or you can say string. So first declaration is s one s one is character array sizes five, then we are assigning a b c d e a and all the characters are enclosed in single quotes, then as to all the characters are enclosed in single quotes. But at the end, we have null character as well. So if you store null, so number of elements will be less. Because one location will be occupied by null character. And third declaration is basically having double quotes. So in double quotes, you can put any number of character basis on the size. So sizes five, so number of characters are four, because fifth location will be occupied for null character. Right? So here one by one explanation is available. So s one is basically array of character. The first declaration will be known as array of character because here we are not assigning null, right? s two is string because it contains null at the end. But it is very difficult to initialize in this way because for each character, you are putting single quotes. So to simplify this, we have third notation. So s three is using double quotes. And here null is inserted automatically. So it is also a string, right? So third one is the suggestive way. Whenever you want to store a string, so just put double quotes inside double quotes, you can put number of characters basis on the size of your array. And last index will be for null. So this way, third notation is the beneficial one. So I hope with this explanation, you are able to understand how we can declare string, how memory is allocated, and how we can assign values to strings. Now, if you want to read values for string from user, so we have two different ways. So first one is string, sorry, first one is scanf. So through scanf, if you use percent s, so you will be able to read values from user, right? So all the values will be stored in the string which you declared. So here, if you read the explanation, it says this statement reads sequence of characters from console. Console means your screen where you provide some input until user processes space or enter key, right? So whenever you press space or enter key, so reading will be terminated. This is important to understand. So this statement automatically inserts null character at the end of string, right? So whenever you are entering some characters, so you just need to enter the characters, null character will be inserted automatically. And next we have GATUS. So GATUS is another way to read string. So this statement reads sequence of characters from console, console again from where you provide some input or see the output until user presses enter key. So here, if you press space, so that will also gets input, right? So it will be stored. So if you want to terminate the input, so you need to press enter key only. And the statement automatically inserts null character at the end of string, right? So this way we have two different ways. We have two different ways to read string values from user, right? And I will be using these methods in the program that I will be demonstrating going forward. Now, after reading some values into string, there may be chances you want to print whatever values are available in the string as output. So we have printf with %s, we have put us with str directly, and we have a loop. So as we are discussing about string, and initially I told you in string, whenever we put some character, so at the end, null character will be available, right? So here we are iterating a loop which is starting from zero, and it will iterate till null. So if str of i is not equals to null, then this loop will be iterating. If it is equals to null, so it will be terminated. So basically what is happening, this loop is printing character one by one through %c. Okay, so these three different ways we have if we want to display the values which we have in string, right? So I hope you understood whatever I explained. If you just want to revise so you can just go backward and watch the video again so that you can understand whatever I have explained so far. Okay, now after understanding the basics of string, after understanding basics of string, we need to know how we can implement the program. So here you can see for today's session, I have four programs that I will be implementing for you, right? So all these four programs I will be implementing practically and you will be able to understand how string related programs we can implement in c programming. And this is very much important to know. So here we have first question which says find out length of a string, right? So length of a string means we need to count how many characters are stored in a string. So for that, I'm moving to online compiler. Okay, so here first of all, I am creating one character array, its size is 10, right? So initial size is 10, but we doesn't know. We don't know how many characters will be provided by user because here I'm writing enter your, let's say, first name, enter your first name and I'm using get us str, right? So what is happening? String size is 10, but you doesn't you don't know how many characters will be provided here? Okay, because we are using get us and you you will be just typing your name and we'll be pressing enter key. Now we need to count how many characters are there. So I'm creating one count variable, which is zero and I then I'm starting a loop from zero, then I'm writing str of I not equals to null. And then I plus plus. Right? So understand this loop carefully. As you know, whenever we are working with a string, so string will be containing some characters. And at the end of last character, we will be having null characters. So this is the way we can represent null character using backslash zero, right? So if str of I not equals to null, then we will be counting this variable plus plus count plus plus count will be incremented by one every time. Right? So I hope you are able to understand this. So I is starting from zero, then str of I means str of zero index. If zero index is not equals to null, then count will be incremented. And then I will be incremented. So I will become one. So str of one, next time in second rotation, this loop will check str of one. So if str of one index is not equals to null, again, count will be incremented. Right? So before null, whatever characters we are having in a string, all those will be counted and the value will be available into count variable. And once this loop completes its execution cycle, then we can display the value of count. So I can write count equals to percent d and then count, right? So number of characters will be counted in this count variable, and that will be displayed as output. Okay, so initially we declared some variable, then we received value from user, then we applied some process through this loop so that we can count number of values. And then through this printf, we are showing the result on output. Now what I'm going to do, I'm just clicking on run. So it is starting its execution. Yeah, so here some warning is available, the gattus function is dense rush and should not be used. Why so? Because here size is 10 and gattus is not checking total size, but it is a warning. It is not an error. Right? It is a warning. It is not an error. So here I'm typing my name Sanjay and pressing enter. And you can see count is equals to six. So this way this code is working fine. Whatever number of characters I entered it counted it correctly. Okay, so I hope with this demonstration you are able to understand the first example. Now what I'm going to do, I'm going to implement solution for another that is copy a string into another string. So I will be having two strings. One string will be having data that data I need to copy into another string second string. And then I will be showing both the strings and we'll see whether they are having same data or not. Okay, so this this will be interesting to implement. So here I'm having s one of 10 and s two of 10. So this way two strings are declared. And I think count is not required here. We will be using variable I only. Then here I'm entering first name into s one. So s one is actually having some data. Now this loop will also iterate on s one loop will also iterate on s one because data is available in s one. And when we iterate this loop, and if loop is on like loop is iterating and if it is before null, so data will copy if s one is now on null character, then this loop will be terminated. So what I'm going to do I'm going to write s two of I equals to s one of I so generally in assignment what will happen data of string one will copy into string two right data of string one will copy into string two biggest string one is written on right hand side right hand side value will get copied into left hand side. So that's where it is written. Okay, and I will be incremented. So condition is totally dependent on s one because here you can see we are reading data into s one only. So basis on s one this loop will iterate. And once null character is available. So this loop will be terminated. Now there is one question that we need to focus when this s one will be on null character. So this loop will be terminated. So this means all the characters from s one will copy into s two except null character, because when s one I indexes on null character, then this loop will be terminated. Okay, so what we need to do we we just need to write s two of I equals to null. Right? So at last index of s two, we need to explicitly store null character so that it can become a string. This is important. Okay, so this this loop is for copy. We are copying data from s one into s two. And all the characters will be copied except null, because at null this loop will be terminated. So after completion of this loop, what is happening? We are assigning null into s two explicitly. Now I am going to show values of both the strings. First time showing s one. Now I'm going to copy this pasting it going to show s two. Right? So this way both s one s two will be displayed. But input we will be providing to s one and s two will show the same value as we have in s one. Right? So this way, with this code, your string will be copied into another string. So I'm clicking on run. It is asking string. I am entering Sanjay. And here you can see s one and s two both are showing Sanjay on output. And I entered Sanjay into s one only. But s two is also having the same data. Right? So this way, with the help of this loop, I was able to store the first string content into second string. Okay, so I hope with this demonstration, you are able to understand. And if you are watching this session, maybe live or recording, so do practice. If you are BTEC student for you, these videos are very much important. And if you are from non technical background, you want to learn programming. So for you also, these sessions are very much important. So do practice so that you can also become expert in programming. Right? So next is count how many wall or consonants are available in a string. So now we need to apply some if condition so that we can count accordingly. So right now I'm going to solve question number three. So in question number three, we need to count how many wall and consonants are available in a string. So let's see how I will be solving this problem. So from here, I'm going to remove this. And I need to count wall and consonant. So here, I'm using two variables, we and see both are initialized with zero. This loop will be same. And here I need to put some logic and rest of the code I'm raising so that I can implement the logic first. So this loop will be same because we need to iterate the string until null is available. So before null, whatever character is available, we need to check whether it is wall or consonant. So we will be checking walls because total five walls are available. Consonants are 21. So instead of focusing on constants, we'll be focusing on walls. And if we identify whether characters wall or not. So if it is wall, wall variable will be counted. If it is not, then consonant variable will be counted. So here I'm writing s one of I equals to a or s one of I double equals to e or s one of I double equals to oh, sorry, oh, then in next line and writing. So if you have space, you can write in single line as well.  So total five conditions are here. And in between I'm using or because or says if anyone is true, then it will be considered as true. So in that case, I will be incrementing V plus plus else C plus plus because if string index element, the character which is stored, if it is equals to either a or e or I or oh, or you, then it is wall, otherwise it is consonant.  Now once this process is completed, we need to display wall and consonant. So I'm writing printf wall equals to post in the V, then again printf backslash and consonants equals to post in D and C. So this way, number of wall and consonants will be displayed. Right now I'm going to run this code. Again, I am entering my name so that I can see number of wall and consonant. So here you can see in my first name, Sanjay, there are only two walls that is a and a and four consonants are available. Right? So I hope with this demonstration, you are able to understand how we can count number of wall and consonants. So do practice for this and you can see in this for loop also, we are using conditional statement, we are using logical operator. So whatever we have learned so far, everything we are using together to implement solution for a business problem. Right? So I hope with this demonstration, you are able to understand the concept of string that is used in C programming. Now the last question, which is also very interesting, we need to count occurrence of a particular character in a string. So occurrence means how many times particular character is available in a string. Okay, so what we'll do will be first reading the string, right? Then we will be reading what character you want to count, right? So whatever character user will be entering that character will be counting like how many times that character is available in the string. Okay, so now I'm going to modify this. So I'm keeping C equals to zero as is and here I'm creating one more variable CH. Then here I'm reading and the character you want to count then scan F, percent C and ampersand CH, right? So first I will be reading the first name, then I will be reading a character like the character, how many times that is available in the string. And here I will be applying the logic. So loop will be same because we need to iterate the loop till null character. So until null is available, loop will process. And here we will be writing S one off I double equals to CH. So S one off I is the string character. CH is the character that we want to search. And if both are matching, so we can say count plus plus. So whenever this if condition is true, so count will be incremented by one. So this way we will be able to identify how many times this CH variable is available into this S one string, right? So this way counting will be done. And at the end, we'll be displaying total number of count. So here I'm writing count equals to and then see and this printf I'm raising. Okay, so this way this program solution is implemented clicking on run. Again, I'm entering Sanjay and it is asking number like num it is asking for the character. So I entered a and you can see in my first name Sanjay number a sorry character is available twice. So it is counted as two. So this way, whatever string you will be entering. So in that string, whatever character you want to count, you can read in this CH variable and basis on this condition that character will be counted. Right? So I hope with this demonstration, you are able to understand the working of string. So do practice whatever I demonstrated in this video. And please provide a review or feedback. And I also created one exercise sheet. So it is updated to the latest. So this is exercise sheet for this C and C plus plus coding bootcamp. So in all the sessions, whatever examples I demonstrated, all are consolidatedly available here.  So you can just follow the sheet. So live session link is available followed by the practice questions. So you can watch the session and then you can practice, right? So till 15 16 17 day 17. So today's session I will be updating tomorrow. So day 17 till day 17. As of now, all the live session links in practice exercise is available. And as I will be delivering more sessions, so all those will be available here also. Right? And the topic list is available in the session tracker that you can follow. So all the session details are available here. So if you follow, you will be able to understand. So like for beginners, C and C plus plus programming is very much important. So that's why please follow this bootcamp, do regular practice so that you can understand the concepts very well. And in C plus plus Java, A picks programming, whatever we'll be learning here will be beneficial for you. Okay, so with this note, I take your leave. And tomorrow I will be having one more session on strings. So do join that. And in upcoming sessions, I will be covering more topics. And soon we'll be starting C plus plus related sessions as well. So keep following the sessions and share this information with other friends as well so that they can also be benefit. Okay, with this note, I take your leave. Thank you so much for joining this session live. And if you're watching the recording, thanks to you as well.


The Nigerian Senate has confirmed the appointment of Justice Olukayo de Aruola as the substantive Chief Justice of Nigeria CJN. His confirmation follows a screening hearing at today's plenary more in this report. Aruola was orchard into the Senate chambers by the Senior Special Assistant to the President and National Assembly Martyrs Senator Babajidi Omowarare. When it was time to speak, the new Chief Justice of Nigeria who came in company of top judiciary officials in the country observed protocol and shared his profile. Lauren, the screening process, federal lawmakers questioned Aruola on various subjects. So I want the reassurance from you that you will insist on the right of judiciary that whatever is due to judiciary is given to you. I like for you to speak on your vision and your plan for repositioning of the Nigerian judiciary. We witness a necessary delay in the administration of justice in our country. The Supreme Court suffers that the most, maybe because we need more justice at our court. And whether my Lord will subscribe to the fact that more justice should be appointed in the Supreme Court, that is one. And my Lord, under your leadership, if confirmed today, how will you address the issue of this delay in the administration of justice in our country? If confirmed as the Chief Justice of Nigeria, my Lord, how will you ensure that the judiciary under your leadership is better equipped to perform this role? And what will be your strategy to ensure that the judiciary is better funded to enhance the capacity of our judicial officers and staff? Responding, the new CJN promised to project the Nigerian judiciary to greater height with the collaboration of the executive and legislative arms of government. We need to appoint more justices. But as we said, the rules will have to be amended. There are many cases that should not be allowed to come out. Many cases should be allowed to stop at the court of appeal. It is only by the constitutional amendment that that can happen. And the constitution can only be amended not by the courts, but by the distinguished House, Senate. National Assembly should please help us, the country, help the nation. Mending this one must end here. He also responded to questions on the administration of criminal justice and the poor funding of the judiciary. The only way we can move is for us to have fund. The judiciary of Nigeria must be properly funded. Judges should not be seen to go cap in hand. No. We should not beg for our entitlement. We should not. We have too much to do than to go about begging. The Senate, however, voted to confirm Arwola after the Senate screened him for nearly two hours. Will the Senate confirm the nomination of honorable justice for Arwola for appointment as Chief Justice of Nigeria? Thank you very much. The nomination of honorable justice for Arwola is hereby confirmed as the Chief Justice of Nigeria. Arwola has been acting as the CGN since the 27th of June this year following the recommendation of the National Judicial Council to make justice Arwola the substantive Chief Justice of Nigeria.