Skip to content

Instantly share code, notes, and snippets.

@spellancer
Created April 14, 2012 15:29
Show Gist options
  • Save spellancer/2385225 to your computer and use it in GitHub Desktop.
Save spellancer/2385225 to your computer and use it in GitHub Desktop.
laba5 result c++
// Laba5.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <stdio.h>
#include <conio.h>
#include <iostream>
using namespace std;
#include <locale.h>
extern "C" { char* ADD1 (int a,char *str);}
int main()
{
setlocale (0,"russian");
int a,c,k,n,i;
int *t;
int *b;
char str[37], *str1;
k=1;
n=0;
cout<<"Ââåäèòå ñòðîêó äëÿ ïîäñ÷åòà: "<<endl;
cin>>str;
while (k!=0)
{
a=strlen(str);
str1=ADD1(a,str);
cout<<"\nÈñõîäíàÿ ñòðîêà:"<<str<<endl;
cout<< "\nÏîëó÷åííàÿ ñòðîêà ñ ðåçóëüòàòîì: "<<str1<<endl;
return 0;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment