473,385 Members | 1,655 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Getting the size of Class

Suppouse you have given a datatype say X in C.
I want to know how to get the size of the datatype without declaring
a varriable or pointer of that type.And ofcourse without using sizeof
operator.

Aug 6 '07 #1
4 1615
On Aug 6, 9:40 am, deba <debabrata.deb...@gmail.comwrote:
Suppouse you have given a datatype say X in C.
I want to know how to get the size of the datatype without declaring
a varriable or pointer of that type.And ofcourse without using sizeof
operator.
Well obviously without using sizeof: I mean why
would you want to use the operator specifically
designed to solve your exact problem ?
Tshh

Aug 6 '07 #2
deba wrote:
Suppouse you have given a datatype say X in C.
I want to know how to get the size of the datatype without declaring
a varriable or pointer of that type.And ofcourse without using sizeof
operator.
Homework?

--
Ian Collins.
Aug 6 '07 #3
Yah dis question was asked in interview.Plz reply it

Aug 6 '07 #4
deba wrote:
Yah dis question was asked in interview.Plz reply it
I did.

It's been asked so many times before, I'm sure you can find the answer
in archives of this group or c.l.c.

--
Ian Collins.
Aug 6 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: middletree | last post by:
How do I request the actual page name that I'm on? This is going to go into an include file, and depending on which page I'm on, I'd like to do different things. I'm looking for "pagename.asp"
8
by: abbylee26 | last post by:
User enters account number if another account number is needed User clicks add account which creates another row When validating when they hit submit I want to check to make sure they tell us...
4
by: Shayne H | last post by:
How can I create a structure that gets passed to an API call that will automatically set its size field? I tried the following: <StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Ansi)> _...
0
by: ruju00 | last post by:
I am getting an error in Login() method of the following class FtpConnection public class FtpConnection { public class FtpException : Exception { public FtpException(string message) :...
8
by: Amit | last post by:
I have a master page and a content page but the stylesheet isnt getting applied like how it looks in visual studio design view. The master page is defined like this: <%@ Master Language="VB"...
3
by: tshad | last post by:
I have a page that I am getting a username and password as a random number (2 letters, one number and 4 more letters) I have 2 functions I call: *************************************************...
1
davydany
by: davydany | last post by:
Hey guys...a n00b Here for this site. I'm making a sequence class for my C++ class. And The thing is in the array that I have, lets say i put in {13,17,38,18}, when i see the current values for the...
3
by: kibong | last post by:
I am trying to get what the user inputs into the box and then take that to check their answers and make sure everything is correct before moving on. here is my code <%@ Page Language="vb" %> ...
2
by: rustyc | last post by:
Well, here's my first post in this forum (other than saying 'HI' over in the hi forum ;-) As I said over there: ... for a little side project at home, I'm writing a ham radio web site in...
2
by: karinmorena | last post by:
I'm having 4 errors, I'm very new at this and I would appreciate your input. The error I get is: Week5MortgageGUI.java:151:cannot find symbol symbol: method allInterest(double,double,double)...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.