ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
tip   To Refer this Site to Your Friends   Click Here
Google
 
Categories  >>  Software  >>  Programming Languages  >>  C
 
 


 

 
 C interview questions  C Interview Questions
 C++ interview questions  C++ Interview Questions
 VC++ interview questions  VC++ Interview Questions
 Delphi interview questions  Delphi Interview Questions
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions
Question
How to use c/c++ code in JAVA
 Question Submitted By :: Rusmguys
I also faced this Question!!     Rank Answer Posted By  
 
  Re: How to use c/c++ code in JAVA
Answer
# 1
basically c is similar to java than c++, its better to use 
the code in c which is very similar to java...
 
Is This Answer Correct ?    7 Yes 3 No
Guest
 
  Re: How to use c/c++ code in JAVA
Answer
# 2
in the form of headerfiles
 
Is This Answer Correct ?    2 Yes 1 No
Ramu
 
 
 
  Re: How to use c/c++ code in JAVA
Answer
# 3
use c/ c++ linkage specifications
 
Is This Answer Correct ?    5 Yes 0 No
Mohmedali
 
  Re: How to use c/c++ code in JAVA
Answer
# 4
Java Native Interface
is only correct ans.
it provide JNI.H header file.

only use method in java.
then
use the run command
javah -jni classname,
it creates classname.h header cpp file
we produce classname.cpp file 
and 
use run command 
cl /LD classname.cpp

it produces .dll file

then
we compile and run java file
without using these steps u can't compile or run it.it 
produces error because the method used in java is not 
defined,,,
 
Is This Answer Correct ?    7 Yes 1 No
Jaya Prakash
 
  Re: How to use c/c++ code in JAVA
Answer
# 5
yes the above answer ids write but when i try to run the c
file i got an error as 

'cl' is not recognized as an internal or external command,
operable program or batch file.

can anyone tell me whether i should include any directory
path ..
otherwise please tell me the steps  that should be done
before running the c file
 
Is This Answer Correct ?    3 Yes 0 No
Manchu
 
  Re: How to use c/c++ code in JAVA
Answer
# 6
Using "native" keyword
 
Is This Answer Correct ?    2 Yes 0 No
Thangavelbalu
[Tekton]
 
  Re: How to use c/c++ code in JAVA
Answer
# 7
why to run back in c/c++ when u r using java which includes
All the features of c/c++
 
Is This Answer Correct ?    0 Yes 1 No
Gaurav
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
explain memory layout of a C program  1
what is the different between if-else and switch statment (other than syntax) CTS9
create an SINGLE LINKED LISTS and reverse the data in the lists completely  3
#include <stdio.h> int main ( int argc, char* argv [ ] ) { int value1 = 10; int value2 = 5; printf ( "\n The sum is :%d", value1 | value2 ); } This is the answer asked by some one to add two numbers with out using arithmetic operator?Yes this answer is write it given out put as 15.But how????? what is need of following line? int main ( int argc, char* argv [ ] ) how it work?what is the meaning for this line? please explain me.Advance thanks Excel4
what is the use of fflush() function?  1
what is meant by c  4
write a program to find the number of even integers and odd integers in a given array in c language Olive-Tech2
What is C language Terminator? TCS12
Why the use of alloca() is discouraged? Oracle2
const char * char * const What is the differnce between the above tow?. TCS5
what is the difference between strcpy() and memcpy() function?  1
How can draw a box in cprogram without using graphics.h header file & using only one printf(); ? NIIT1
void main() { char far *farther,*farthest; printf("%d..%d",sizeof(farther),sizeof(farthest)); } ME3
What is Heap?  3
Write a programme to find even numbers without using any conditional statement? Infosys3
Program to find the value of e raised to power x using while loop N-Tech3
what is the other ways to find a logic to print whether a number is an even or odd wit out using % symbol??????? i know three different ways to print it. so i need any other different logic>>>>> TCS3
if ENTERED FIVE DIGITS DESIGN A PROGRAM THAT WILL FIND CORRESPONDING VALUE FROM ASCII TABLE  1
what are the uses of structure? HCL5
who did come first hen or agg Infosys12
 
For more C Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com